aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGustav Hållberg <gustav@gmail.com>2012-04-06 21:32:38 +0200
committerGustav Hållberg <gustav@gmail.com>2012-04-07 21:50:34 +0200
commit6805d5c71e7863b5a8925dbf4029cb3239c7a7e7 (patch)
tree12b517621cc05d71f2ca6272c6c5581cb4c88530
parent724dba9c7f2ba8a0ba585b7d443637211aa56b33 (diff)
downloadstgit-6805d5c71e7863b5a8925dbf4029cb3239c7a7e7.tar.gz
stgit.el: Unexpand all (normal) patches when switching branches
Signed-off-by: Gustav Hållberg <gustav@gmail.com>
-rw-r--r--contrib/stgit.el6
1 files changed, 6 insertions, 0 deletions
diff --git a/contrib/stgit.el b/contrib/stgit.el
index 73973e1..4ecb8b8 100644
--- a/contrib/stgit.el
+++ b/contrib/stgit.el
@@ -1814,6 +1814,12 @@ If SKIP-CURRENT is not nil, do not include the current branch."
,@(unless (zerop (length branch-point))
(list branch-point)))))
t)))
+
+ ;; Do not expand any (normal) patches in the new branch
+ (setq stgit-expanded-patches
+ (remove-if-not (lambda (p) (memq p '(:work :index)))
+ stgit-expanded-patches))
+
(stgit-reload))))
(defun stgit-available-refs (&optional omit-stgit)