GIT

Work with central repository

  • Display all branches in central repository
    $ git branch -r
  • Removing remote branch from central repository
    git push origin --delete <branch_name>

Work with working directory

Branch

  • How to fetch all branches: for me allways works using git branch –track <remote_branch>
    for remote in $(git branch -r | grep -v "HEAD"); do git branch --track $remote; done
  • Creating and switching into new branch
    git checkout -b <master-2> master
  • Switch to another branch
    git checkout <master-2>
  • Creating new branch on central repository
     git push origin <master-2>
Navigation
Print/export
Toolbox