Follow vim-fugitive's quickfix flows in diff and merge views

Ouverte
#31 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Les mainteneurs répondent en général sous 1 jour

@CoreyKaylor y travaille déjà.

Depuis le 6/11/2026.

  • #32 par @CoreyKaylor — ouverte

Évaluation

Difficulté
5/5
Temps estimé
Plus d'une semaine
Accessibilité débutants
35/100
Type d'issue
Fonctionnalité
Clarté
Plutôt claire
Activité
Active
Stack technique
lua, vim
Domaine
devtools

Piste de recherche

Start by reading the :DiffBanditMerge and diff view entry points, then trace how sessions handle buffer changes, quickfix navigation, and Git commands from fugitive buffers; the issue does not name specific files or tests. Done when the listed fugitive flows use the correct file and comparison in place, commands work from fugitive buffers, and moving on from an untouched merge preserves its buffer.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Description

enhancement help wanted

This came out of a question on #1: does the merge view work with fugitive's :Git mergetool? The flow asked about is to load the conflicts into the quickfix list, run :DiffBanditMerge on the current buffer, and move between files with :cnext and :cprev.

It doesn't work today, and other fugitive flows have similar problems.

Problems

Merge views don't follow the quickfix list. :cnext to another file puts that file in the result pane, conflict markers included, while the session keeps tracking the old file. Running :DiffBanditMerge again stacks another tab.

Closing a merge can overwrite the conflicted file with base text. This doesn't need fugitive. :DiffBanditMerge on a file that's already open writes base text into its buffer and never restores it. After closing without edits, the buffer stays modified with its conflict markers gone, so a later :wall replaces the file on disk. Git still reports UU.

Leaving a file can break quickfix entries. A view that loaded a file wipes its buffer on the way out, so the next jump to that file fails with E92: Buffer not found. ]f then :cnext triggers it, and so does the merge walk under nohidden.

Git commands fail from fugitive's buffers. From the status buffer or any fugitive:// buffer, they fail with fatal: cannot change to 'fugitive:///...'.

Diff views don't follow the quickfix list either. After :Git difftool, :cnext leaves the right pane on another file. A jump from the left pane ends the session.

Views ignore the comparison a list describes. After :Git difftool HEAD~1, the view still compares against HEAD, so an entry can land on the wrong change. :Gclog can't move a commit review between commits.

What's wanted

  • :cnext, :cprev and related commands move merge and diff views in place, from any pane.
  • :Git difftool [range] and :Gclog lists show the comparison or commit each entry describes.
  • Git commands work from fugitive's buffers, using the file or commit under the cursor in the status buffer.
  • An opt-in setting opens DiffBandit from :Git mergetool, :Git difftool and dd in the status buffer.
  • Closing or moving on from an untouched merge leaves the file's buffer as it was, and unsaved edits survive moving between files.
Langage dominant
Lua
Étoiles
298
Forks
4
Merge moyen
1 j 4 h
PR mergées (30 j)
11

Préparer son environnement

Ce projet ne fournit ni conteneur de développement, ni Dockerfile, ni guide de contribution : l'installation est à votre charge. Commencez par son README, et consultez notre guide de la première contribution pour les étapes générales.

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de CoreyKaylor/diffbandit.nvim

Toutes les issues de CoreyKaylor/diffbandit.nvim

Issues similaires

Plus d'issues Lua

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.