Skip to content

Instantly share code, notes, and snippets.

View douglas's full-sized avatar

Douglas Soares de Andrade douglas

View GitHub Profile
@douglas
douglas / gist:1100860
Created July 23, 2011 02:07
Rename (it seems to create a new) branch on github
Execute this command:
$ git push origin remote_branch_name:new_branch_name
Remember that you should edit the repository info to change to the new branch so you can delete the old one with this command:
$ git push origin :old_branch_name
@douglas
douglas / selenium_with_python.rst
Created July 22, 2011 23:24 — forked from baijum/selenium_with_python.rst
Selenium with Python

Selenium with Python

Author: Baiju Muthukadan
Email:baiju.m.mail AT gmail.com
Version: 0.3.2
@douglas
douglas / gist:1072807
Created July 8, 2011 21:00
How to delete a remote branch
$ git push origin :remote_branch_name
@douglas
douglas / gist:1072791
Created July 8, 2011 20:52
Remove an unwanted commit on git and github
# force git/github to ignore a unwanted commit and use HEAD^ as HEAD of the repository
$ git push -f origin HEAD^:remote_branch
OR
$ git rebase -i HEAD~2
$ git push origin +master
References:
@douglas
douglas / gist:1066406
Created July 6, 2011 02:27
Install swig on a ubuntu box
sudo apt-get install swig
@douglas
douglas / gist:1066392
Created July 6, 2011 02:19
Install swig on a archlinux box
sudo pacman -S swig
@douglas
douglas / gist:1066385
Created July 6, 2011 02:10
Changing git repository without needing to delete and clone the repository
# first see the current origin
git remote -v
# now we delete the origin
git remote rm origin
# now we set the new origin
git remote add origin [email protected]:user/reponame.git
# optional: make git pull and push from someremote (on our case, origin)
@douglas
douglas / install_swig_mac.sh
Created July 6, 2011 01:47
Install swig on a mac with homebrew
brew install https://raw.github.com/cobrateam/formulae/master/swig.rb