Git and working on multiple branches

后端 未结 6 1261
春和景丽
春和景丽 2020-12-02 06:42

I have a couple of Git branches: \'experimental\', \'something\' and \'master\'.

I switched to the \'experimental\' branch. I noticed a bug which is unrelated to \'e

6条回答
  •  鱼传尺愫
    2020-12-02 06:59

    you could:

    • stash or commit the changes you have been working on the experimental branch
    • checkout something
    • (optional) bisect to find the bug
    • commit the changes
    • checkout experimental

    and then:

    • rebase something if you want a clean commit graph (if you expose this repository and you care about that)

    or:

    • merge something if you don't care about 'presentation' :)

提交回复
热议问题