Git diff patch 怎么弄?

时间:2018-03-29 14:21:51   收藏:0   阅读:239

现有一个commit号,
然后修改什么的,git commit 生成一个新的commit号,
git diff 旧的commit号码 新的commit号码 > /c/www/abc.patch
这样就能看到有个patch文件了,
----
如何apply一个patch
ECLIPSE->右键->team->applY patch
选择合适的level [ignore leading path name segments]看到没有红叉就可以了吧
然后和原始的进行比较 确认
-----
从根目录下的Git bash生成的**.patch都会有a/根目录/xx/x/x/什么的
所以apply patch的时候也是要从根目录开始弄。

原文:https://www.cnblogs.com/qinqiu/p/8669234.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!