How can I selectively merge or pick changes from another branch in Git?

前端 未结 25 2118
慢半拍i
慢半拍i 2020-11-22 02:53

I\'m using Git on a new project that has two parallel -- but currently experimental -- development branches:

  • master: import of existing codebase pl
25条回答
  •  半阙折子戏
    2020-11-22 03:25

    I found this post to contain the simplest answer. Merely do:

    git checkout  
    

    Example

    Pulling .gitignore file from branchB into current branch:

    git checkout branchB .gitignore
    

    See the post for more information.

提交回复
热议问题