One of the features of version control systems is the ability to isolate changes onto a separate line of development. This line is known as a branch. Branches are often used to try out new features without disturbing the main line of development with compiler errors and bugs. As soon as the new feature is stable enough then the development branch is merged back into the main branch.
Another feature of version control systems is the ability to mark particular revisions (e.g. a release version), so you can at any time recreate a certain build or environment. This process is known as tagging.
Git is very powerful at branching and tagging. It is very easy to create branches and tags.
Creating a branch is very simple:→
Branch: input your branch name.
Creating a tag is very simple:→
Tag: input your tag name.
You can choose one commit that base on.
Current commit checked out.
The latest commit of chosen branch.
The commit of chosen tag.
Any commit, you click
If you want your working tree to be switched to the newly created branch automatically, use the Switch to new branch/tag checkbox. But if you do that, first make sure that your working tree does not contain modifications. If it does, those changes will be merged into the branch working tree when you switch.
track is a checkbox with three values. If it is checked
--track is passed to git on OK, if it is unchecked
--no-track is passed to git on OK. The third state indicates, that neither
--no-track is passed to git on OK - see
branch.autosetupmerge configuration variable (the section called “git-config(1)”) and
--track parameter documentation for the section called “git-branch(1)”.
When using GPG 1.4 (which is shipped with Git for Windows) this requires a key without a passphrase. GPG >= 2 comes with an agent like pageant and, thus,.also works with passphrase protected keys, however, you might need to configure git to use the right gpg.exe. This can be done be setting the configuration variable
C:/Program Files (x86)/GNU/GnuPG/pub/gpg.exe). We tested this with Gpg4win (GPG4win vanilla is sufficient and with version 2.2.x it is also compatible to GPG 1.4 key files).
Press local repository.to create branch or tag at
Note that unless you opted to switch your working tree to the newly created branch, creating a Branch or Tag does not affect your working tree. Even if you create the branch from your working tree, those changes are committed to the original branch, not to the new branch.
On how to switch working tree to tag/branch, please refer to the section called “Checking Out A Working Tree (Switch to commit)”.