Skip to content

Instantly share code, notes, and snippets.

View d3cline's full-sized avatar
🎯
Focusing

John Spounias d3cline

🎯
Focusing
View GitHub Profile
@d3cline
d3cline / quickstart.sh
Created May 19, 2019 20:48 — forked from i12n/quickstart.sh
A simple 'hello world' python application with uwsgi and nginx
# A simple 'hello world' application with python uwsgi and nginx
# Make directory and files
# The directory structure:
# ./
# |-- app/
# | |-- hello.py
# | |-- hello_nginx.conf
if [ -d app ]; then
rm -rf app
@d3cline
d3cline / validators.py
Created May 18, 2019 02:51
Django DomainNameValidator adapted from EmailValidator
from django.core.exceptions import ValidationError
from django.core.validators import validate_ipv46_address
from django.utils.deconstruct import deconstructible
from django.utils.encoding import force_text
from django.utils.translation import ugettext_lazy as _
import re
@deconstructible
class DomainNameValidator(object):
@d3cline
d3cline / ReadSerialPort.cs
Created March 10, 2017 06:30 — forked from mkchandler/ReadSerialPort.cs
Some C# code to read a serial port. Using this as a starting point for an Arduino project.
using System;
using System.IO.Ports;
namespace SerialReader
{
class Program
{
static void Main(string[] args)
{
var reader = new ArduinoSerialReader("COM3");