# [question] How to customize git revert template

3 messages from 2024-02-29 to 2024-03-04. Participants: Wu Zhenyu, Kristoffer Haugsbakk.
Thread: https://gitlist.dev/t/61028

## Wu Zhenyu, 2024-02-29 12:52

Subject: [question] How to customize git revert template
Message-ID: <k4zvycdixqmntkyevdtsrswbfiklyj24mp6jhltnwwdswxromc@q3wtrivkbfbl>
URL: https://gitlist.dev/e/k4zvycdixqmntkyevdtsrswbfiklyj24mp6jhltnwwdswxromc%40q3wtrivkbfbl

```
In https://git-scm.com/docs/git-revert

> While git creates a basic commit message automatically

How can I customize git revert template? e.g.,

ˋˋˋsh
git config revert.template ~/.config/git/template
ˋˋˋ

TIA!

-- 
Best Regards
Wu Zhenyu

```

## Kristoffer Haugsbakk, 2024-02-29 15:18

Subject: Re: [question] How to customize git revert template
Message-ID: <9389c159-ba55-4329-9d86-bc95b321737f@app.fastmail.com>
URL: https://gitlist.dev/e/9389c159-ba55-4329-9d86-bc95b321737f%40app.fastmail.com
In-Reply-To: <k4zvycdixqmntkyevdtsrswbfiklyj24mp6jhltnwwdswxromc@q3wtrivkbfbl>

```
Hi

On Thu, Feb 29, 2024, at 13:52, Wu Zhenyu wrote:
> In https://git-scm.com/docs/git-revert
>
>> While git creates a basic commit message automatically
>
> How can I customize git revert template? e.g.,
>
> ˋˋˋsh
> git config revert.template ~/.config/git/template
> ˋˋˋ
>
> TIA!
>
> --
> Best Regards
> Wu Zhenyu

I see no way to customize this message. Your only choices seem to be

1. This default
2. The “reference” style using `--reference`

So there doesn’t seem to be a template alternative here.

-- 
Kristoffer Haugsbakk


```

## Wu Zhenyu, 2024-03-03 14:44

Subject: Re: [question] How to customize git revert template
Message-ID: <6x4ybwweqseahgnfdvzm7jhrtyk5q3of7fq6bmx6kei7bqf56s@dgd57y57m5je>
URL: https://gitlist.dev/e/6x4ybwweqseahgnfdvzm7jhrtyk5q3of7fq6bmx6kei7bqf56s%40dgd57y57m5je
In-Reply-To: <9389c159-ba55-4329-9d86-bc95b321737f@app.fastmail.com>

```
Can git support the feature to customize template? Is it possible?

TIA!

On Thu, Feb 29, 2024 at 04:18:20PM +0100, Kristoffer Haugsbakk wrote:
> Hi
> 
> On Thu, Feb 29, 2024, at 13:52, Wu Zhenyu wrote:
> > In https://git-scm.com/docs/git-revert
> >
> >> While git creates a basic commit message automatically
> >
> > How can I customize git revert template? e.g.,
> >
> > ˋˋˋsh
> > git config revert.template ~/.config/git/template
> > ˋˋˋ
> >
> > TIA!
> >
> > --
> > Best Regards
> > Wu Zhenyu
> 
> I see no way to customize this message. Your only choices seem to be
> 
> 1. This default
> 2. The “reference” style using `--reference`
> 
> So there doesn’t seem to be a template alternative here.
> 
> -- 
> Kristoffer Haugsbakk
> 
> 

-- 
Best Regards
Wu Zhenyu



```
