Working with Branches in Git

Show all the branches

git branch

Create a new branch

git branch my_experimental_feature

Use that branch

git checkout my_experimental_feature

Pushing the new branch to a remote server

git push origin my_experimental_feature

Pulling that branch down on another machine

git pull origin my_experimental_feature

Listing all branches on other machine

git branch -a

Updating other machine

git pull origin my_experimental_feature
6 Sep 2009, 3:25pm
Git:
by bseanvt

leave a comment

Non Standard Port Number with SSH and Git

Here is an example using the port 4567 to connect with over ssh and git

ssh remote add origin ssh://sean@seanbehan.com:4567/path/to/git
git push origin master