The following commands are used for creating the local branches: Learn how to create local/remote repos/branches I will create a few branches in both repositories and then use the commands to list all branches as well as branches in the remote repository only with screenshots.įor our example, I have created a few branches in local as well as remote repositories. In the next section, I will show you an example of a remote and local repository. So, it becomes quite handy to know the way of listing all branches in the repo that helps in switching to appropriate branch as well. Our repositories may contain a number of branches and sometimes it is hard to remember all – whether on the local or remote repo. You may also use the show-branch command for seeing the branches and their commits as follows:Īs working with Git version control system, we have to work with branches. If you require only listing the remote branches from Git Bash then use this command: The command to list all branches in local and remote repositories is:
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |