How to create a new branch from a tag?

后端 未结 7 2158
不思量自难忘°
不思量自难忘° 2020-12-12 08:56

I\'d like to create a new master branch from an existing tag. Say I have a tag v1.0. How to create a new branch from this tag?

7条回答
  •  不思量自难忘°
    2020-12-12 09:36

    I used the following steps to create a new hot fix branch from a Tag.

    Syntax

    git checkout -b  
    

    Steps to do it.

    1. git checkout -b NewBranchName v1.0
    2. Make changes to pom / release versions
    3. Stage changes
    4. git commit -m "Update pom versions for Hotfix branch"
    5. Finally push your newly created branch to remote repository.
    git push -u origin NewBranchName
    

    I hope this would help.

提交回复
热议问题