Skip to content

Instantly share code, notes, and snippets.

View draptik's full-sized avatar

Patrick Drechsler draptik

View GitHub Profile

Keybase proof

I hereby claim:

  • I am draptik on github.
  • I am draptik (https://keybase.io/draptik) on keybase.
  • I have a public key whose fingerprint is 10A4 B0E4 277F CD15 9F08 845D B063 1437 5124 4030

To claim this, I am signing this object:

# pacman -S python-virtualenvwrapper
$ echo 'WORKON_HOME=$HOME/.virtualenvs' >> ~/.bashrc
$ . ~/.bashrc
$ mkdir -p $WORKON_HOME
$ echo 'source /usr/bin/virtualenvwrapper.sh' > ~/.bashrc
$ . ~/.bashrc
$ mkvirtualenv -p python2.7 --distribute blog_env
@draptik
draptik / backup_large_files
Created October 9, 2012 19:36
Backup script using rdiff-backup, duplicity and rsync
#!/bin/bash
#
# Setup:
#
# +--------+ +-----+
# | MyData | | HDD |
# | | (1) rdiff-backup | |
# | | ------------------> | |
# | | | | +-----+
# | | (2) duplicity | | (3) rsync | USB |
@draptik
draptik / ps1_git.sh
Created August 11, 2012 13:42
PS1 prompt with git branch
# Idea from:
#
# https://bbs.archlinux.org/viewtopic.php?pid=1068202
# Colors https://wiki.archlinux.org/index.php/Color_Bash_Prompt
# Note: We require escape '\[' and '\]' around the ansi escapes
# (i.e. '\e[0m')! Otherwise the shell does not know that the ansi
# escapes should be excluded from the line wrapping calculation.
#
# See