git

git 生成patch

2017-03-13  本文已影响86人  谢昆明

general step to generate patch without commit at last

  1. commit your local changes using
    git commit -a -m "specific message"
    Note : don't push this commit.

  2. generate patch
    git format-patch -s -n -1 HEAD
    it will generate 0001-.patch

  3. revert back local commit
    git reset --soft HEAD~1
    to delete commit but keep your work
    git reset --hard HEAD~1
    to delete commit with your work

打赏

如果这篇文章解决了您的问题,让我买根烟抽抽。

支付宝.jpg 微信.jpg
上一篇 下一篇

猜你喜欢

热点阅读