Skip to content

Instantly share code, notes, and snippets.

View kogakure's full-sized avatar
🏠
Working from home

Stefan Imhoff kogakure

🏠
Working from home
View GitHub Profile
@kogakure
kogakure / .bash_profile
Created December 9, 2008 17:11
Bash: .bash_profile, .bashrc
source ~/.bashrc
# Unix Aliase
alias ll="ls -lisa"
alias la="ls -la"
alias ls-l="ls -l"
alias cd..="cd .."
alias ..="cd .."
alias ...="cd ../.."
alias workssh="ssh user@domain"
@kogakure
kogakure / update_latest_revisions.py
Created December 9, 2008 17:16
Python: Updates Subversion, Git, Mercurial and Bazaar repositories recursive
#!/usr/bin/python
import os
import os.path
from subprocess import call
if __name__ == "__main__":
apps_dir = os.path.abspath('.')
for app_name in os.listdir(apps_dir):
app_dir = os.path.abspath(os.path.join(apps_dir, app_name))
git_path = os.path.join(app_dir, '.git')
@kogakure
kogakure / commit_latest_revisions.py
Created December 9, 2008 17:19
Python: Commits all Git and Git-SVN repositories
#!/usr/env/python
import os
import os.path
from subprocess import call
if __name__ == "__main__":
apps_dir = os.path.abspath('.')
for app_name in os.listdir(apps_dir):
app_dir = os.path.abspath(os.path.join(apps_dir, app_name))
git_path = os.path.join(app_dir, '.git')
@kogakure
kogakure / .gitconfig
Created December 9, 2008 17:25
Git: .gitconfig, .gitignore, .gitk
[user]
name = John Doe
email = john.doe@gmail.com
[core]
excludesfile = /Users/doe/.gitignore
[color]
status = auto
diff = auto
branch = auto
interacitve = auto
@kogakure
kogakure / .hgrc
Created December 9, 2008 17:32
Mercurial: .hgrc
[ui]
username = John Doe <john.doe@gmail.com>
[defaults]
cdiff = -q
[extdiff]
cmd.cdiff = colordiff
opts.cdiff = -uprN
@kogakure
kogakure / .vimrc
Last active May 20, 2016 13:01
Vim: .vimrc
" ###################
" # Global Settings #
" ###################
" Default shell
set shell=/bin/zsh
scriptencoding utf-8
" #######
" Bundles
@kogakure
kogakure / settings.py
Created December 9, 2008 17:39
Python: Django Templates: settings.py, local_settings.py
#!/usr/bin/python
# -*- coding: utf-8 -*-
import os.path
import sys
# Basic Settings
PROJECT_ROOT = os.path.dirname(os.path.abspath(__file__))
PROJECT_NAME = os.path.split(PROJECT_ROOT)[-1]
MEDIA_ROOT = '%s/media/' % PROJECT_ROOT
@kogakure
kogakure / delpyc.sh
Created December 9, 2008 17:45
Bash: Delete Python compiled files recursive
#!/bin/bash
find ./ -type f -name "*.pyc" -exec rm -f {} \;
@kogakure
kogakure / pylink.sh
Created December 9, 2008 17:45
Bash: Link Python package into `site-packages`
@kogakure
kogakure / umlaute.pl
Created December 9, 2008 17:47
Perl: Remove all Umlauts and special characters from filenames
#!/usr/bin/perl
#===============================================================================
#
# FILE: renametree.pl
#
# USAGE: ./renametree.pl
#
# DESCRIPTION: rename files and directories in the current tree to
# eliminate special characters