Hi,

I see you are already using gerrit and know about
https://github.com/GerritCodeReview/git-repo/blob/master/hooks/commit-msg
That is reading, parsing and changing the commit message so I'm sure you
can start with that.
It will even be triggered at "git commit --amend --no-edit" to not display
the text editor for manual change.

But is it possible you might want to edit commits of all the history and in
that case other approach might be necessary.

Alex

On Wed, Jul 25, 2018 at 2:57 AM Timothy Rice <[email protected]>
wrote:

> > This wont work for me because am trying the edit the commit message ,not
> > change the commit message altogether
>
> Ah, I see. In that case the only thing that comes to mind for me is to
> write up a bash script:
>
> 1. Grab the last commit message (probably by munging git log).
> 2. Pipe it through some tool like sed to do the programmatic modification.
> 3. Redirect that into `git commit --review -m "..."`.
>
> ~ Tim
>
> --
> You received this message because you are subscribed to the Google Groups
> "Git for human beings" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to