など。私はmaster
に基づいてfeature
ブランチを持っています。新しいコミットは1つで、2つのファイルが追加されています。Git:マスタでのリベース時にローカルブランチの変更が適用されない
commit hash1
A test.html
A test.png
は、今私は、最新のコードを取得するためにmaster
にこのfeature
ブランチをリベースします。私がfeature
ブランチで作業を開始して以来、新しいコミットはmaster
に追加されました。
commit hash2
A test.html
私がgit rebase master
を実行しているとき、私はこの出力を得ました。完全に否定feature
、test.html
から結果変化として
First, rewinding head to replay your work on top of it...
Applying: Initial commit.
Using index info to reconstruct a base tree...
M test.html
Falling back to patching base and 3-way merge...
error: The following untracked working tree files would be overwritten by merge:
test.html
Please move or remove them before you can merge.
Aborting
Failed to merge in the changes.
Patch failed at 0001 Initial commit.
The copy of the patch that failed is found in:
/<path>/.git/rebase-apply/patch
When you have resolved this problem, run "git rebase --continue".
If you prefer to skip this patch, run "git rebase --skip" instead.
To check out the original branch and stop rebasing, run "git rebase --abort".
はmaster
からバージョンであり、test.png
は全く添加しませんでした。
この状況を解決するにはどうすればよいですか?
"test.pngはまったく追加されませんでした。"現在のエラーが解決され、 'git rebase --continue'が実行されたときにだけ追加されます。 – VonC