Skip to content

Instantly share code, notes, and snippets.

@mmbrian
mmbrian / django_settings_update
Created Nov 13, 2014
One-line scp commad to update django settings.py from local repository
View django_settings_update
scp settings.py username@username.webfactional.com:/home/username/webapps/app/myproject/myproject/settings.py
@mmbrian
mmbrian / post-receive
Created Nov 13, 2014
Minimal git post-receive hook for a django app on WebFaction
View post-receive
#!/bin/sh
GIT_WORK_TREE=/home/username/webapps/app/myproject git checkout -f master
GIT_WORK_TREE=/home/username/webapps/app/myproject git reset --hard
PATH=/home/username/webapps/app/apache2/bin:$PATH
restart
@mmbrian
mmbrian / gist:6403258
Created Sep 1, 2013
Unity 2D Solutions
View gist:6403258
http://forum.unity3d.com/threads/124772-2D-Animation-Solution-your-opinion-and-experience
http://forum.unity3d.com/threads/120867-Comparison-of-2D-toolkits-available-in-Asset-Store
http://mudry.me/iphone-2d-game-development-with-unity-3d/
@mmbrian
mmbrian / SherlockHomeAsBackButton
Created Aug 23, 2013
Make SherlockActivity's Home button act as back button
View SherlockHomeAsBackButton
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
getSupportActionBar().setHomeButtonEnabled(true);
}
@Override
public boolean onOptionsItemSelected(MenuItem item) {