branch: elpa/magit commit e275aaa88807e407d6e17393c50f5b92f222f45a Author: Jonas Bernoulli <jo...@bernoul.li> Commit: Jonas Bernoulli <jo...@bernoul.li>
magit-commit-squash-internal: Always add either --no-edit or --edit Adding "--edit" is not actually necessary, because the variants that need it, use other arguments, which imply it. But users don't always know which arguments imply which of these two arguments, so it is a nice touch to include this information in the arguments, shown in the process buffer. This also makes it easier to document the behavior of variants; we can now say that some of them use "--edit", without that not actually being true. --- lisp/magit-commit.el | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lisp/magit-commit.el b/lisp/magit-commit.el index 681c7c6b61a..b804bcab2f1 100644 --- a/lisp/magit-commit.el +++ b/lisp/magit-commit.el @@ -337,8 +337,7 @@ depending on the value of option `magit-commit-squash-confirm'." magit-commit-squash-confirm)))) (let ((magit-commit-show-diff nil)) (push (concat option commit) args) - (unless edit - (push "--no-edit" args)) + (push (if edit "--edit" "--no-edit") args) (if rebase (magit-with-editor (magit-call-git