git@vger.kernel.org mailing list mirror (one of many)
 help / Atom feed
* enhancement: support for author.email and author.name in "git config"
@ 2018-12-06 18:17 William Hubbs
  2018-12-06 18:38 ` Martin Ågren
  0 siblings, 1 reply; 6+ messages in thread
From: William Hubbs @ 2018-12-06 18:17 UTC (permalink / raw)
  To: git; +Cc: chutzpah, williamh

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

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: enhancement: support for author.email and author.name in "git config"
  2018-12-06 18:17 enhancement: support for author.email and author.name in "git config" William Hubbs
@ 2018-12-06 18:38 ` Martin Ågren
  2018-12-06 19:17   ` William Hubbs
  0 siblings, 1 reply; 6+ messages in thread
From: Martin Ågren @ 2018-12-06 18:38 UTC (permalink / raw)
  To: williamh; +Cc: Git Mailing List, chutzpah

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

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: enhancement: support for author.email and author.name in "git config"
  2018-12-06 18:38 ` Martin Ågren
@ 2018-12-06 19:17   ` William Hubbs
  2018-12-06 22:20     ` Johannes Schindelin
  0 siblings, 1 reply; 6+ messages in thread
From: William Hubbs @ 2018-12-06 19:17 UTC (permalink / raw)
  To: Martin Ågren; +Cc: Git Mailing List, chutzpah, williamh

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

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: enhancement: support for author.email and author.name in "git config"
  2018-12-06 19:17   ` William Hubbs
@ 2018-12-06 22:20     ` Johannes Schindelin
  2018-12-07 22:21       ` William Hubbs
  0 siblings, 1 reply; 6+ messages in thread
From: Johannes Schindelin @ 2018-12-06 22:20 UTC (permalink / raw)
  To: William Hubbs; +Cc: Martin Ågren, Git Mailing List, chutzpah

[-- Attachment #1: Type: text/plain, Size: 681 bytes --]

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

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: enhancement: support for author.email and author.name in "git config"
  2018-12-06 22:20     ` Johannes Schindelin
@ 2018-12-07 22:21       ` William Hubbs
  2018-12-07 22:44         ` Jonathan Nieder
  0 siblings, 1 reply; 6+ messages in thread
From: William Hubbs @ 2018-12-07 22:21 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Martin Ågren, Git Mailing List, chutzpah

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

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: enhancement: support for author.email and author.name in "git config"
  2018-12-07 22:21       ` William Hubbs
@ 2018-12-07 22:44         ` Jonathan Nieder
  0 siblings, 0 replies; 6+ messages in thread
From: Jonathan Nieder @ 2018-12-07 22:44 UTC (permalink / raw)
  To: William Hubbs
  Cc: Johannes Schindelin, Martin Ågren, Git Mailing List, chutzpah

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

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, back to index

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-06 18:17 enhancement: support for author.email and author.name in "git config" William Hubbs
2018-12-06 18:38 ` Martin Ågren
2018-12-06 19:17   ` William Hubbs
2018-12-06 22:20     ` Johannes Schindelin
2018-12-07 22:21       ` William Hubbs
2018-12-07 22:44         ` Jonathan Nieder

git@vger.kernel.org mailing list mirror (one of many)

Archives are clonable:
	git clone --mirror https://public-inbox.org/git
	git clone --mirror http://ou63pmih66umazou.onion/git
	git clone --mirror http://czquwvybam4bgbro.onion/git
	git clone --mirror http://hjrcffqmbrq6wope.onion/git

Newsgroups are available over NNTP:
	nntp://news.public-inbox.org/inbox.comp.version-control.git
	nntp://ou63pmih66umazou.onion/inbox.comp.version-control.git
	nntp://czquwvybam4bgbro.onion/inbox.comp.version-control.git
	nntp://hjrcffqmbrq6wope.onion/inbox.comp.version-control.git
	nntp://news.gmane.org/gmane.comp.version-control.git

 note: .onion URLs require Tor: https://www.torproject.org/
       or Tor2web: https://www.tor2web.org/

AGPL code for this site: git clone https://public-inbox.org/ public-inbox