Git - Committer

About

The committer is the person who committed the code or applied the patch on behalf of the original author. It's generally a project maintainer or core member.

Default

The default Committer is the OS user.

How to set the committer of a new commit?

GIT_COMMITTER_NAME='Committer' GIT_COMMITTER_EMAIL='[email protected]' git commit --author 'Author <[email protected]>'

Committer information is taken from the following environment variables, if set:

GIT_COMMITTER_NAME
GIT_COMMITTER_EMAIL
GIT_COMMITTER_DATE

How to see the committer information?

By default on git log, only the author data shows.

To see the committer date you can either format the log specifically for that:

git log --pretty='%cn %cd' -n1 HEAD
# where `cn` and `cd` stand for `Committer Name` and `Committer Date`

or use the fuller predefined format:

git log --format=fuller

How to set the committer date of a new commit?

GIT_COMMITTER_DATE='2000-01-01T00:00:00+0000' git commit --date='2000-01-01T00:00:00+0000'

where:





Discover More
Git Commit Tree Data Model
Git - Commit

A commit in git is an object that stores the information : who saved the file system snapshots, when they were saved, why they were saved. the commiter the author the parent commit It's...
Git - User

The user originally for Git is the author. But Git knows two persons: the author: the person who originally wrote the code / the patch. the committer: the person (project maintainer or core member)...



Share this page:
Follow us:
Task Runner