This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import types | |
import cStringIO | |
TYPE_NULL = '0' | |
TYPE_NONE = 'N' | |
TYPE_FALSE = 'F' | |
TYPE_TRUE = 'T' | |
TYPE_STOPITER = 'S' | |
TYPE_ELLIPSIS = '.' | |
TYPE_INT = 'i' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
cat /var/lib/dbus/machine-id && exit | |
# Provided by dbus, hence available on all systemd systems. | |
# Any user can read it and it is persistent accross boots. | |
# It is unique per installation, and works well in VMs. | |
# Not all systems (i.e. stage3 gentoo/handbook install) | |
# have dbus installed by default. | |
cat /sys/class/dmi/id/product_uuid && exit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: latin-1 -*- | |
import android | |
import urllib2 | |
droid = android.Android() | |
def translate(to_translate, to_langage="auto", langage="auto"): | |
'''Return the translation using google translate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import re | |
from django import template | |
from django.utils.functional import allow_lazy | |
from django.template.defaultfilters import stringfilter | |
from django.utils.safestring import mark_safe, SafeData | |
from django.utils.encoding import force_unicode | |
from django.utils.html import escape | |
from django.utils.text import normalize_newlines | |
register = template.Library() |