list branches
git branch
create (and checkout) new branch
git checkout -b crazy-experiment
delete branch (after merging)
git branch -d crazy-experiment
delete branch (not merged but you don't want the branch anymore)
git branch -D crazy-experiment

The above command will not delete the branch in the remote repo. To delete the branch in the remote repo as well do the following

delete remote branch
git push origin --delete crazy-experiment
git push origin :crazy-experiment

  • 0 posts
  • 0 subtopics
  • 6 days ago by vince