5.5 Deleting Branches
Branches can outlive their usefulness. The release was tagged; the experiment was proven successful or failed. When this happens, you should delete the branch to keep your repository’s branches from growing out of control.
After you merge your changes back into your current branch, such
as the about2 branch you created,
you can use the -d parameter on
git branch to delete the old branch:
|
prompt> git branch -d about2 |
|
|
Deleted branch about2. |
This works only when the branch you’re trying to delete has been
successfully merged into the current branch you are on. To demonstrate
this, let’s switch back to the master branch.
Remember, we haven’t merged any of our changes from the
about branch yet. ...