bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#21559: 25.0.50; auto-revert-mode breaks git rebase


From: Ben Gamari
Subject: bug#21559: 25.0.50; auto-revert-mode breaks git rebase
Date: Sun, 07 Feb 2016 11:55:07 +0100
User-agent: Notmuch/0.21+24~gbceb651 (http://notmuchmail.org) Emacs/25.1.50.1 (x86_64-pc-linux-gnu)

I've spoken with some folks in #git about this issue.

 * the index lock is held "because it needs to read the index and
   compare it to the worktree. If it doesn't take the index lock, other
   things could change either the index or the worktree underneath it,
   making git status lie (or even crash)"
   
 * It sounds as though a patch refactoring `git rebase` such that it
   holds the index lock may be considered, although this is a
   non-trivial refactoring as `rebase` is currently a shell script

 * One option would be to check whether a rebase is in progress before
   auto-reverting. In pseudo-shell,

   if [ -e .git/rebase-apply ] || [ -e .git/rebase-merge ]; then
      do_not_call_git_status_because_we_are_rebasing;
   else
      auto_revert
   fi

   Unfortunately it sounds like this wouldn't do the right thing when a
   rebase pauses due to conflict (when you'd ideally want to
   auto-revert).

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]