Skip to content

Instantly share code, notes, and snippets.



View GitHub Profile
ObserverOfTime /
Last active Oct 28, 2020 — forked from ambivalentno/
A form field to handle validation of image + svg.
from xml.etree import cElementTree as et
from django.core.exceptions import ValidationError
from django.forms import ImageField
class SVGImageField(ImageField):
"""A Django ImageField that accepts SVG images."""
def to_python(self, data):
#!/bin/bash -e
# Semantic version comparison using semver specification
# This bash script compares pre-releases alphabetically as well
# returns 1 when A greater than B
# returns 0 when A equals B
# returns -1 when A lower than B
ObserverOfTime / css-inject.js
Last active Mar 29, 2019 — forked from 1j01/
GitHub Desktop Dark Theme - NO LONGER MAINTAINED
View css-inject.js
* To apply the theme:
* 1) Open dev tools with CTRL + SHIFT + I
* 2) Go to the console
* 3) Paste the following code
* Note: You will have to do this again whenever Github Desktop updates
const fs = require('fs');
const path = require('path');