上游分支(不是主要/默认HEAD,如果有关系的话)有一些我想要的更新,而其他大多数我没有。
首先,我做了git fetch -v upstream
而不是pull
,因为我还不想修改本地代码(在我的master分支中)。
执行git merge upstream/nonmaster
会自动合并很多我绝对不想要的东西,删除许多从未从我的fork上游运行的本地文件(因为它是不同的作者/副项目),等等。
问题,如何将其设置为git mergetool
将启动配置的GUI( kdiff3 ),以便允许我选择要保留在面板A(基本)/所有更改的文件中B(我的)/ C(他们的)(上游完全丢失了一些,但是我绝对想保留在我的分支中)?
当前,它返回“无需合并文件”,尽管git diff HEAD
显示了差异,显然可以自动合并。我不要自动;我想选择要合并/更改的内容,在大多数情况下,请保持原样。
我可以一次完成一个文件...请问如何?
说git checkout -m upstream/save -- README.md
作为测试文件。
包括(相关问题)[How to move a file back into the conflict state after conflict resolution?在内的多个来源指的是git checkout -m ...
但是,我仍然面对“无需合并文件” ,并且毕竟并没有强制解决冲突,而git diff HEAD
显示了我通常不希望的自动合并的更改。>
git status; git diff HEAD
On branch master
Your branch is up-to-date with 'origin/master'.
Changes to be committed:
(use "git reset HEAD <file>..." to unstage)
modified: README.md
diff --git a/README.md b/README.md
index 9a7e6a0..1be114b 100644
--- a/README.md
+++ b/README.md
@@ -21,22 +21,23 @@ Setup
-Before you begin, make sure you have `Python3` installed. Robinhood shell only works with python3. Some of the functionality is broken on python2.7
+Download Robinhood Shell by downloading the zip file ([link](https://github.com/ploch/RobinhoodShell/archive/dev.zip)) OR by using git
-1. Download Robinhood Shell by downloading the zip file ([link](https://github.com/anilshanbhag/RobinhoodShell/archive/dev.zip)) OR by using git
+=======
```
-git clone https://github.com/anilshanbhag/RobinhoodShell.git
+git clone https://github.com/ploch/RobinhoodShell.git
COROLLARY(可能吗?)
我们如何在git管道中手动创建冲突标记,否则git merge
会认为它已经自动完成了工作?