Re: [PATCH 2/8] revert: decouple sequencer actions from builtin commands
From: Ramkumar Ramachandra <hidden>
Date: 2016-06-15 22:52:46
Hi Jonathan,
I wrote a new commit message for this patch. Perhaps it can help clarify?
revert: decouple sequencer actions from commands
Currently, we have two actions "pick" and "revert" that directly
correspond to the action of the commands 'git cherry-pick' and 'git
revert' respectively. Since we would like to permit mixing different
actions in the same instruction sheet inspired by the way 'git rebase
--interactive' works, a future instruction sheet would look like:
pickle next~4
revert rr/moo^2~34
action3 b74fea
where the actions "pickle", "revert" and "action3" need not directly
correspond to the specific commands. So, instead of using the same
representation for both the command executed and the sequencer action
(the "replay_action" enum), store the command separately as a
"replay_command" enum.
Since we don't allow mixing actions yet, the entire operation of 'git
cherry-pick'/ 'git revert' relies on the command, with the
exception of the instruction sheet parser which converts a
"replay_action" to a "replay_command". As we support mixing actions
in future patches, more portions of the code will rely on the
action, demoting the command to a string used in error reporting.
-- Ram