Skip to content

Instantly share code, notes, and snippets.

View jezdez's full-sized avatar
🚴
💨

Jannis Leidel jezdez

🚴
💨
View GitHub Profile
@jezdez
jezdez / howto.txt
Created February 12, 2010 01:33 — forked from simonw/howto.txt
Save the supervisord.initscript script as /etc/init.d/supervisord
Run /usr/sbin/update-rc.d -f supervisord defaults
@jezdez
jezdez / gist:314471
Created February 25, 2010 11:35 — forked from mmalone/gist:299905
"Memcached cache backend"
from django.core.cache.backends import memcached
from django.utils.encoding import smart_unicode, smart_str
MIN_COMPRESS_LEN = 150000
class CacheClass(memcached.CacheClass):
def add(self, key, value, timeout=None, min_compress_len=MIN_COMPRESS_LEN):
if isinstance(value, unicode):
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by subversion configure 1.6.9, which was
generated by GNU Autoconf 2.64. Invocation command line was
$ ./configure --disable-debug --prefix=/usr/local/Cellar/subversion-python/1.6.9 --with-ssl --with-zlib=/usr/lib --disable-neon-version-check --disable-mod-activation --without-apache-libexecdir --without-berkeley-db
## --------- ##
## Platform. ##
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by subversion configure 1.6.9, which was
generated by GNU Autoconf 2.64. Invocation command line was
$ ./configure --disable-debug --prefix=/usr/local/Cellar/subversion-python/1.6.9 --with-ssl --with-zlib=/usr/lib --disable-neon-version-check --disable-mod-activation --without-apache-libexecdir --without-berkeley-db
## --------- ##
## Platform. ##
@jezdez
jezdez / pip.conf
Created March 10, 2010 14:57
My ~/.pip/pip.conf. More information here: http://pip.openplans.org/configuration.html
[global]
default-timeout = 60
respect-virtualenv = true
download-cache = ~/.pip/cache
log-file = ~/.pip/pip.log
build = ~/.pip/build
[install]
use-mirrors = true
The goal of Summer of Code is to get your project written, reviewed, and
ultimately merged back into Django's trunk. We want your project to
succeed, and we approved it because we think you've got a good chance of
pulling it off.
However, this is easier said than done. You'll need to work hard,
communicate effectively with the community, and pass a rigorous peer
review. Your mentor -- and Django's committer team in general -- will give
you as much support as possible, but ultimately the onus is on your
shoulders to get this done.
diff --git a/django/utils/dateformat.py b/django/utils/dateformat.py
index 13cc2c7..efec5c3 100644
--- a/django/utils/dateformat.py
+++ b/django/utils/dateformat.py
@@ -128,7 +128,7 @@ class DateFormat(TimeFormat):
ISO 8601 Format
Example : '2008-01-02T10:30:00.000123'
"""
- return self.data.isoformat(' ')
+ return self.data.isoformat()
>>> locale.locale_alias
{'a3': 'a3_AZ.KOI8-C',
'a3_az': 'a3_AZ.KOI8-C',
'a3_az.koi8c': 'a3_AZ.KOI8-C',
'af': 'af_ZA.ISO8859-1',
'af_za': 'af_ZA.ISO8859-1',
'af_za.iso88591': 'af_ZA.ISO8859-1',
'am': 'am_ET.UTF-8',
'am_et': 'am_ET.UTF-8',
'american': 'en_US.ISO8859-1',
from django import template
register = template.Library()
@register.filter
def with_title(field, title=None):
return field.as_widget(attrs={'title': title})
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
[svn-remote "svn"]
url = http://code.djangoproject.com/svn
fetch = django/trunk:refs/remotes/svn/trunk
branches = django/branches/releases/*:refs/remotes/svn/*
tags = django/tags/releases/*:refs/remotes/svn/tags/*