Skip to content
Snippets Groups Projects
  • Gregory Szorc's avatar
    2cbbd4622ab0
    convert: config option to control Git committer actions · 2cbbd4622ab0
    Gregory Szorc authored
    When converting a Git repository to Mercurial at Mozilla, I encountered
    a scenario where I didn't want `hg convert` to automatically add the
    "committer: <committer>" line to commit messages. While I can hack around
    this by rewriting the Git commit before it is fed into `hg convert`,
    I figured it would be a useful knob to control.
    
    This patch introduces a config option that allows lots of control
    over the committer value. I initially implemented this as a single
    boolean flag to control whether to save the committer message. But
    then there was feedback that it would be useful to save the committer
    in extra data. While this patch doesn't implement support for saving
    in extra data, it does add a mechanism for extending which actions
    to take on the committer field. We should be able to easily add
    actions to save in extra data.
    
    Some of the implemented features weren't asked for. But I figured they
    could be useful. If nothing else they demonstrate the extensibility
    of this mechanism.
    2cbbd4622ab0
    History
    convert: config option to control Git committer actions
    Gregory Szorc authored
    When converting a Git repository to Mercurial at Mozilla, I encountered
    a scenario where I didn't want `hg convert` to automatically add the
    "committer: <committer>" line to commit messages. While I can hack around
    this by rewriting the Git commit before it is fed into `hg convert`,
    I figured it would be a useful knob to control.
    
    This patch introduces a config option that allows lots of control
    over the committer value. I initially implemented this as a single
    boolean flag to control whether to save the committer message. But
    then there was feedback that it would be useful to save the committer
    in extra data. While this patch doesn't implement support for saving
    in extra data, it does add a mechanism for extending which actions
    to take on the committer field. We should be able to easily add
    actions to save in extra data.
    
    Some of the implemented features weren't asked for. But I figured they
    could be useful. If nothing else they demonstrate the extensibility
    of this mechanism.