improve commit popup and commands #1228

merged 6 commits into from Feb 22, 2014


None yet
1 participant

tarsius commented Feb 22, 2014

Also see #1220.

tarsius added some commits Feb 22, 2014

magit-commit-{fixup,squash}: default to commit at point
Previously these commands either used the commit at point (or the marked
commit), no questions asked, or they had the user make a choice without
providing a default.  Now a default is provided by putting point on the
commit that was at point in the previous buffer.

This also looses the ability to use the marked commit (whether
unconditionally or as default).  That option being available was the
result of me being urged to merge the squash functionality into master
before I considered it fully ready.
magit-commit-popup: remove redundant --amend switch
The popup features several commands dedicated to amending.
magit-commit{,*}: use magit-current-popup-args inside interactive
The variable `magit-current-popup-args' serves a purpose similar to that
of `current-prefix-args' and should therefor be processed inside the
`interactive' form whenever possible.  The commands changed here now
have a new ARGS argument.  This also has the advantage that it is now
possible in non-interactive use to set these arguments.
magit-commit-assert: fail if --all and nothing un-/staged
Because everything of nothing is still nothing.
magit-commit-assert: add special case for amend variants
For some amend command variants it does not make sense to allow an amend
operation to proceed with no changes.  Add argument STRICT to utility
`magit-commit-assert' to allow aborting in such cases and set that when

@tarsius tarsius merged commit 317ba27 into next Feb 22, 2014

@tarsius tarsius deleted the n/commit-popup-1 branch Feb 22, 2014

@tarsius tarsius added this to the 2.1.0 milestone Feb 22, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment