How to Set Commit Author

Publikováno: 13.3.2019

I’ve worn dozens of hats on a dozen different teams during my time at Mozilla, but none has been as rewarding and challenging as community management. Whether it’s mentoring students, welcoming new contributors, or reviewing pull requests, there’s always so much to be done. There’s also the rare occasion where I need to submit a […]

The post How to Set Commit Author appeared first on David Walsh Blog.

Celý článek

I’ve worn dozens of hats on a dozen different teams during my time at Mozilla, but none has been as rewarding and challenging as community management. Whether it’s mentoring students, welcoming new contributors, or reviewing pull requests, there’s always so much to be done. There’s also the rare occasion where I need to submit a patch for a contributor.

Since I work with both git and mercurial (hg), I’ve needed to learn how to set commit author in each version control system.

To set the commit author with git, you would execute:

git commit --author="User Name <username@domain.com>" -m "The commit message"

To set the commit author with mercurial, you would execute:

hg commit -u "User Name <username@domain.com>" -m "The commit message"

Giving community members credit for their patches is the ultimate sign of respect, so in the case you need to translate those patches for a contributor, these snippets are gold. Help them help you!

The post How to Set Commit Author appeared first on David Walsh Blog.

Nahoru
Tento web používá k poskytování služeb a analýze návštěvnosti soubory cookie. Používáním tohoto webu s tímto souhlasíte. Další informace