Skip to content

Instantly share code, notes, and snippets.

View jezdez's full-sized avatar
🚴
💨

Jannis Leidel jezdez

🚴
💨
View GitHub Profile
@jezdez
jezdez / gist:1242317
Created September 26, 2011 14:10
cut -f1 -d" " .bash_history|sort|uniq -c|sort -r
1769 git
1258 cd
596 python
562 mate
525 brew
386 ./manage.py
288 pip
249 sudo
227 ssh
202 workon
@jezdez
jezdez / -
Created October 10, 2017 15:45
https://gist.github.com/d9d140f8caf9e740ac91b55365158aa8
@jezdez
jezdez / -
Created October 10, 2017 14:29
android-sdk
apache-spark
aria2
asio
aspell
autoconf
autoenv
automake
axel
bash
@jezdez
jezdez / app_group_patch.py
Created April 28, 2016 20:01
Patch Click to use a Flask 1.0 AppGroup by default to get automatic app context for commands
import click
try:
from flask.cli import AppGroup
except ImportError:
from flask_cli import AppGroup
def group(name=None, **attrs):
"""The same as ``click.grop`` but sets the default command class
@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
  1. The code will get better. Linus' Law: "given enough eyeballs, all bugs are shallow": we'll be able to get community contributions and bug reports, and thus the code will grow better faster than we can grow it ourselves. Also, Joy's Law - "No matter who you are, most of the smartest people work for someone else": we'll get better code from people who don't work for us than from people who do.

  2. We'll write better code. Wall's 3rd great virtual of a programmer, Hubris: we'll write better code people we don't want other people to say bad things about us. We'll do better with the world watching than with just us.

  3. Increased ability to hire. We're a 19k circ newspaper in a town most people have never heard of. Open source will help put us on the map, make us a place people actually might be interested in working.

  4. When we do hire, we'll be able to hire pe

@jezdez
jezdez / port.py
Last active December 17, 2015 16:59
a script to re-combine all django-localflavor-* apps
#!/usr/bin/env python
"""Port localflavors
Usage:
port.py clone [--dry-run]
port.py copy [--dry-run]
port.py merge_po [--dry-run]
port.py (-h | --help)
port.py --version
Step1-Identify LCD:
Open Terminal and copy-paste
ioreg -lw0 | grep \"EDID\" | sed "/[^<]*</s///" | xxd -p -r | strings -6
LP154WT1-SJA2 (=LG 2nd revision)
LP154WT1-SJA1 (=LG 1st revision)
LSN154YL01001 (=Samsung)
Step2-Test for IR:
http://www.mitchmalone.name/retina-test/
@jezdez
jezdez / gist:5347395
Created April 9, 2013 16:57
a list of names for the class that is used in the app loading refactor
AppBase
AppPortrait
AppSketch
AppPassport
AppPlan
AppDetails
AppSpec
AppThing
AppTraits
AppFrame
@jezdez
jezdez / common [stash] fields.py
Created December 1, 2012 15:07 — forked from thomasyip/common [stash] fields.py
Updated version of Django BigInt Patch for 64bit Primary Keys
"""
module mydjangolib.bigint_patch
A fix for the rather well-known ticket #399 in the django project.
Create and link to auto-incrementing primary keys of type bigint without
having to reload the model instance after saving it to get the ID set in
the instance.
Logs: