emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[nongnu] elpa/git-commit decd5f40dd 2/2: magit-stash-pop: Use pop instea


From: ELPA Syncer
Subject: [nongnu] elpa/git-commit decd5f40dd 2/2: magit-stash-pop: Use pop instead of apply
Date: Thu, 27 Jul 2023 00:59:56 -0400 (EDT)

branch: elpa/git-commit
commit decd5f40dd514ef559cdbba23c51e2208c25d9ef
Author: Alex Kreisher <akreisher18@gmail.com>
Commit: Alex Kreisher <akreisher18@gmail.com>

    magit-stash-pop: Use pop instead of apply
    
    Restores pop behavior lost in
    bdade489ead0ffd1de0709042d5166837efea4e8.
    Previously, "git stash apply" was used when popping, with an explit
    drop due to handling of the "--index" argument. Now that "--index" is
    passed conditionally, and the drop was removed, the call here can be
    replaced by the expected "git-stash-pop".
---
 lisp/magit-stash.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/magit-stash.el b/lisp/magit-stash.el
index 8c9e9611eb..c8725d23a4 100644
--- a/lisp/magit-stash.el
+++ b/lisp/magit-stash.el
@@ -252,7 +252,7 @@ If nothing is staged, then try to reinstate the stashed 
index.
 Doing so is not possible if there are staged changes.  Do not
 remove the stash, if it cannot be applied."
   (interactive (list (magit-read-stash "Pop stash")))
-  (magit-run-git "stash" "apply" stash
+  (magit-run-git "stash" "pop" stash
                  (and (not (apply #'magit-anything-staged-p nil
                                   (magit-stashed-files stash)))
                       "--index")))



reply via email to

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