git-rerere

Re-use conflict resolution with Git

家住魔仙堡 提交于 2020-01-11 02:02:49
问题 Can I tell Git to re-use the conflict resolution from an existing merge commit? I had rerere disabled at the time of commit. The new merge commit contains a few additional commits on the "ours" side of the merge (but they should not introduce new conflicts as they modified a different set of files). For instance, take the following DAG: m [master] Add new stuff * | o [old-master] Merge branch A (conflicts) |/a [branch A] n * * * */ * Now, what I want to do is to bring commits m and m^ into

Re-use conflict resolution with Git

拟墨画扇 提交于 2020-01-11 02:02:36
问题 Can I tell Git to re-use the conflict resolution from an existing merge commit? I had rerere disabled at the time of commit. The new merge commit contains a few additional commits on the "ours" side of the merge (but they should not introduce new conflicts as they modified a different set of files). For instance, take the following DAG: m [master] Add new stuff * | o [old-master] Merge branch A (conflicts) |/a [branch A] n * * * */ * Now, what I want to do is to bring commits m and m^ into

rebase - automatically continue if rerere resolved all conflicts

大兔子大兔子 提交于 2019-12-20 10:23:56
问题 Git rerere provides for reuse of previous conflict resolutions during rebase, and can even stage the resolved files by setting rerere.autoupdate = True (as detailed in another question). However, even if all conflicts are resolved and all files staged, I still have to run git rebase --continue to continue the rebase operation. How can I automatically continue if rerere has resolved all conflicts and staged all changes? 回答1: No. Rebase or Merge does not automatically provide a provision for

How to “fixup” git rerere resolution

时光毁灭记忆、已成空白 提交于 2019-12-11 18:17:28
问题 My workflow usually consists of merge -> resolve conflicts -> commit -> debug during compilation -> fixup commit . In this way I make dirty merge with clearing afterwards. If I enable rerere I would always have dirty resolutions recorded. How to bypass this problem? Is there a way to fix rerere resolution by following commit? 回答1: My workflow typically consist of: Make changes -> test -> commit -> make more changes -> test -> commit -> repeat. This gives me multiple local commits that

Re-use conflict resolution with Git

白昼怎懂夜的黑 提交于 2019-12-04 03:36:52
Can I tell Git to re-use the conflict resolution from an existing merge commit? I had rerere disabled at the time of commit. The new merge commit contains a few additional commits on the "ours" side of the merge (but they should not introduce new conflicts as they modified a different set of files). For instance, take the following DAG: m [master] Add new stuff * | o [old-master] Merge branch A (conflicts) |/a [branch A] n * * * */ * Now, what I want to do is to bring commits m and m^ into the branch old-master (and later make that the new master). I don't want to simply merge master into old

git rerere does not auto-commit autoupdated merge resolutions

爱⌒轻易说出口 提交于 2019-11-30 06:38:28
问题 I'm trying to use the shared rerere cache to automate throwaway integration/test branches. The idea is that the rerere cache should be up to date when the branch is pushed, so that these merges always pass. However, they don't: >>> git merge --no-ff invoicing Staged 'analysisrequest.py' using previous resolution. Staged '__init__.py' using previous resolution. Auto-merging __init__.py CONFLICT (content): Merge conflict in __init__.py Auto-merging analysisrequest.py CONFLICT (content): Merge

Do I have to commit a merge to make git-rerere record my conflict resolution?

早过忘川 提交于 2019-11-29 11:29:22
问题 I'm using git-rerere for its intended purpose, to record conflict resolutions between two branches (master and a topic branch) incrementally as those branches develop, without creating unnecessary merge commits. However, even after reading the git-rerere manpage I'm a little unclear on when rerere actually records my conflict resolution. My standard workflow for detecting and resolving new merge conflicts is to do git merge master from the topic branch, resolve the conflicts, then stage all

Undo a git rerere resolution that was done in a rebase

萝らか妹 提交于 2019-11-29 10:57:53
问题 Okay, so I really like the git rerere command. Although, I haven't really used it that much other than letting it auto-magically record my conflicts and resolve them for me. However, I did mess up one of my conflict resolutions during quite a large rebase (rebasing a really stale feature branch with the latest release). feature -> a - b - c - d release -> e - f - g - h rebase/feature -> e - f - g - h - a' - b' - c' - d' So, say for instance that b' has an incorrect merge (thanks to me!), and

Have git rerere automatically mark files as resolved?

淺唱寂寞╮ 提交于 2019-11-28 23:17:09
I'm using git rerere, and it is useful, but there is one problem: When it automatically resolves a file, it does not mark it as resolved (eg with git add). So if I run 'git mergetool', it opens up the file as if it still has all the conflicts in it. So far, I've made a small shell script which I can call, which scans all files marked as conflicted for conflict markers (eg >>>>>>> ), and calls git-add on them if they have none. Is there a better way of doing this? Some flag to git rerere I missed? Maybe a git config setting can help: rerere.autoupdate When set to true, git-rerere updates the

git rerere does not auto-commit autoupdated merge resolutions

五迷三道 提交于 2019-11-28 21:32:52
I'm trying to use the shared rerere cache to automate throwaway integration/test branches. The idea is that the rerere cache should be up to date when the branch is pushed, so that these merges always pass. However, they don't: >>> git merge --no-ff invoicing Staged 'analysisrequest.py' using previous resolution. Staged '__init__.py' using previous resolution. Auto-merging __init__.py CONFLICT (content): Merge conflict in __init__.py Auto-merging analysisrequest.py CONFLICT (content): Merge conflict in analysisrequest.py Automatic merge failed; fix conflicts and then commit the result. At this