Git command to create new branch
The Git command to create a new branch is:
git branch <branch-name>
Replace <branch-name>
with the name you want to give to your new branch.
For example, to create a new branch called "feature/new-login-system", you would run:
git branch feature/new-login-system
This will create a new branch with the specified name, but it won't switch you to that branch. If you want to switch to the new branch immediately, you can use the -b
option:
git branch -b feature/new-login-system
This will create the new branch and switch you to it.