Add option to swap the order of incoming and current changes in merge conflict resolver
See original GitHub issueDescription
In my current workflow, the most common merge conflict is additions to the changelog of the project - any incoming change is already merged, thus should be ordered above the current change, however in the current implementation, Refined Github sorts it below the current change.
An example:
- Chanelog contains item A and B at the beginning:
# CHANGELOG
- A
- B
- A PR is opened, adding item D to the changelog:
# CHANGELOG
- A
- B
- D
- Another PR is opened, and merged before the first PR is merged, making the incoming changelog look like this:
# CHANGELOG
- A
- B
- C
- This causes the following merge conflict:
# CHANGELOG
- A
- B
<<<<<<< Incoming change
- D
=======
- C
>>>>>>> Current change
- With the current behaviour of Refined Github, if both changes are accepted, their order wouldn’t be correct. This requires manual fixing. My recommendation is an extra button that swaps the order of the incoming and current changes, which results in the correctly ordered changelog list, with a single click:
# CHANGELOG
- A
- B
- C
- D
Screenshot
No response
Example URL
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Git merge conflict resolution: reverse order of (current ...
Now I want to accept both changes, however, they are in the wrong order. If only the master's change was first, then they...
Read more >VS Code tips — The merge conflict code lens - YouTube
Today's VS Code tip: the merge conflict code lensYou can quickly resolve merge conflicts directly in VS Code. Use the merge conflict code ......
Read more >How to easily merge and resolve git stash pop conflicts
There's no magic remedy for such merge conflicts. The only option for developers is to edit the file by hand and keep what...
Read more >Strategies to resolve git conflicts using "theirs" and "ours"
You can resolve all the conflicts manually by navigating to each file, and accepting all incoming changes to the master.
Read more >Merge conflicts - GitLab Docs
Resolve conflicts in the inline editor · Go to your merge request. · Select Overview, and scroll to the merge request reports section....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Looking at the code in
resolve-conflicts.ts
, this seems like a relatively easy feature to implement, so, why not.Refined GitHub is not Refined Git or a substitute to git tooling, period.
Most conflicts are not going to be resolved by simply swapping the changes so it doesn’t seem worth it to support such an uncommon action.