# enhancement: support for author.email and author.name in "git config"

8 messages from 2018-12-06 to 2018-12-13. Participants: William Hubbs, Martin Ågren, Johannes Schindelin, Jonathan Nieder.
Thread: https://gitlist.dev/t/49962

## William Hubbs, 2018-12-06 18:17

Subject: enhancement: support for author.email and author.name in "git config"
Message-ID: <20181206181739.GB30045@whubbs1.gaikai.biz>
URL: https://gitlist.dev/e/20181206181739.GB30045%40whubbs1.gaikai.biz

```
Hi all,

We are in a situation where we would like to use author information that is
different from committer information when we commit to certain
repositories.

Currently, it looks like there are two ways to do this, and I'm not sure
how to make either of them work well.

There are the GIT_AUTHOR_EMAIL and GIT_AUTHOR_NAME environment
variables, but  these would have to be set globally. Also, there is the
--author command line switch for the "git commit" command, but this is
easy to forget to use.

Is there something I'm missing?

If not, I would like to propose the addition of author.email and
author.name settings to the git-config system.

Additionally you could add committer.name and committer.email, but the
only reason I bring the committer variations up is consistency since I
see you also have GIT_COMMITTER_NAME and GIT_COMMITTER_EMAIL environment
variables.

Does anyone have any thoughts on this?

I don't think either of us is on the mailing list, so please keep us in
CC's when you reply.

Thanks,

William

```

## Martin Ågren, 2018-12-06 18:38

Subject: Re: enhancement: support for author.email and author.name in "git config"
Message-ID: <CAN0heSp2g0A82YYvMw-RaERESXFtj3TgPKA3RysC07Lf=tHBcg@mail.gmail.com>
URL: https://gitlist.dev/e/CAN0heSp2g0A82YYvMw-RaERESXFtj3TgPKA3RysC07Lf%3DtHBcg%40mail.gmail.com
In-Reply-To: <20181206181739.GB30045@whubbs1.gaikai.biz>

```
Hi William,

On Thu, 6 Dec 2018 at 19:18, William Hubbs <williamh@gentoo.org> wrote:
> We are in a situation where we would like to use author information that is
> different from committer information when we commit to certain
> repositories.

[...]

> [...] I would like to propose the addition of author.email and
> author.name settings to the git-config system.
>
> Additionally you could add committer.name and committer.email, but the
> only reason I bring the committer variations up is consistency since I
> see you also have GIT_COMMITTER_NAME and GIT_COMMITTER_EMAIL environment
> variables.

This idea was floated a couple of months ago [1]. Junio seemed to find
the request sensible and outlined a design. No patches materialized, as
far as I know, but that could be because Eric suggested a tool called
direnv. Maybe that would work for you.

[1] https://public-inbox.org/git/0f66ad7a-2289-2cce-6533-a27e19945187@rasmusvillemoes.dk/

Martin

```

## William Hubbs, 2018-12-06 19:17

Subject: Re: enhancement: support for author.email and author.name in "git config"
Message-ID: <20181206191737.GA31091@whubbs1.gaikai.biz>
URL: https://gitlist.dev/e/20181206191737.GA31091%40whubbs1.gaikai.biz
In-Reply-To: <CAN0heSp2g0A82YYvMw-RaERESXFtj3TgPKA3RysC07Lf=tHBcg@mail.gmail.com>

```
On Thu, Dec 06, 2018 at 07:38:08PM +0100, Martin Ågren wrote:
> Hi William,
> 
> [...]
> 
> This idea was floated a couple of months ago [1]. Junio seemed to find
> the request sensible and outlined a design. No patches materialized, as
> far as I know, but that could be because Eric suggested a tool called
> direnv. Maybe that would work for you.
 
 Yes, this design would solve the issue.

 I'll take a look at direnv, but it would be nice to have native git
 support for this. :-)

Thanks,

William

> [1] https://public-inbox.org/git/0f66ad7a-2289-2cce-6533-a27e19945187@rasmusvillemoes.dk/
> 
> Martin

```

## Johannes Schindelin, 2018-12-06 22:20

Subject: Re: enhancement: support for author.email and author.name in "git config"
Message-ID: <nycvar.QRO.7.76.6.1812062318570.41@tvgsbejvaqbjf.bet>
URL: https://gitlist.dev/e/nycvar.QRO.7.76.6.1812062318570.41%40tvgsbejvaqbjf.bet
In-Reply-To: <20181206191737.GA31091@whubbs1.gaikai.biz>

```
Hi William,

On Thu, 6 Dec 2018, William Hubbs wrote:

> On Thu, Dec 06, 2018 at 07:38:08PM +0100, Martin Ågren wrote:
> > Hi William,
> > 
> > [...]
> > 
> > This idea was floated a couple of months ago [1]. Junio seemed to find
> > the request sensible and outlined a design. No patches materialized, as
> > far as I know, but that could be because Eric suggested a tool called
> > direnv. Maybe that would work for you.
>  
>  Yes, this design would solve the issue.

There *is* a way to get what you want that is super easy and will
definitely work: if you sit down and do it ;-)

Please let us know if you need any additional information before you can
start.

Ciao,
Johannes
```

## William Hubbs, 2018-12-07 22:21

Subject: Re: enhancement: support for author.email and author.name in "git config"
Message-ID: <20181207222147.GA22590@whubbs1.gaikai.biz>
URL: https://gitlist.dev/e/20181207222147.GA22590%40whubbs1.gaikai.biz
In-Reply-To: <nycvar.QRO.7.76.6.1812062318570.41@tvgsbejvaqbjf.bet>

```
Hi Johannes,

On Thu, Dec 06, 2018 at 11:20:07PM +0100, Johannes Schindelin wrote:
> Hi William,
> 
>[...]
> 
> There *is* a way to get what you want that is super easy and will
> definitely work: if you sit down and do it ;-)
> 
> Please let us know if you need any additional information before you can
> start.

Which branch should I work off of in the repo?

William

```

## Jonathan Nieder, 2018-12-07 22:44

Subject: Re: enhancement: support for author.email and author.name in "git config"
Message-ID: <20181207224428.GE73340@google.com>
URL: https://gitlist.dev/e/20181207224428.GE73340%40google.com
In-Reply-To: <20181207222147.GA22590@whubbs1.gaikai.biz>

```
William Hubbs wrote:
> On Thu, Dec 06, 2018 at 11:20:07PM +0100, Johannes Schindelin wrote:

>> There *is* a way to get what you want that is super easy and will
>> definitely work: if you sit down and do it ;-)
>>
>> Please let us know if you need any additional information before you can
>> start.
>
> Which branch should I work off of in the repo?

"master".

Also, please make sure the documentation (e.g. in
Documentation/config/user.txt) describes when a user would want to set
this option.

See also:
- Documentation/SubmittingPatches
- the DISCUSSION section of "git help format-patch"
- [1]
- https://www.kernel.org/pub/software/scm/git/docs/user-manual.html#hacking-git

Thanks,
Jonathan

[1] https://github.com/gitgitgadget/gitgitgadget#a-bot-to-serve-as-glue-between-github-pull-requests-and-the-git-mailing-list

```

## William Hubbs, 2018-12-13 19:29

Subject: Re: enhancement: support for author.email and author.name in "git config"
Message-ID: <20181213192930.GA21006@whubbs1.gaikai.biz>
URL: https://gitlist.dev/e/20181213192930.GA21006%40whubbs1.gaikai.biz
In-Reply-To: <20181207224428.GE73340@google.com>

```
Hi Jonathan,

On Fri, Dec 07, 2018 at 02:44:28PM -0800, Jonathan Nieder wrote:
> William Hubbs wrote:
> > On Thu, Dec 06, 2018 at 11:20:07PM +0100, Johannes Schindelin wrote:
> 
> >> There *is* a way to get what you want that is super easy and will
> >> definitely work: if you sit down and do it ;-)
> >>
> >> Please let us know if you need any additional information before you can
> >> start.
> >
> > Which branch should I work off of in the repo?
> 
> "master".
> 
> Also, please make sure the documentation (e.g. in
> Documentation/config/user.txt) describes when a user would want to set
> this option.

Is the git team on an irc channel somewhere, or should I start sending
patches that I know are incomplete to the list?

I would like to work with someone on this since I'm not that familiar
with the git sources. :-)

Thanks,

William


```

## Jonathan Nieder, 2018-12-13 19:37

Subject: Re: enhancement: support for author.email and author.name in "git config"
Message-ID: <20181213193754.GA7306@google.com>
URL: https://gitlist.dev/e/20181213193754.GA7306%40google.com
In-Reply-To: <20181213192930.GA21006@whubbs1.gaikai.biz>

```
William Hubbs wrote:

> Is the git team on an irc channel somewhere,

Some like to use #git-devel on freenode.

>                                              or should I start sending
> patches that I know are incomplete to the list?

Yeah, that's fine.  Include [WIP/PATCH] in the subject line to set
appropriate expectations. :)

Thanks,
Jonathan

```
