user3675188
user3675188

Reputation: 7409

How to show git log without date information

My current git log will show relative date information,

How to disable it ?

603f78e - Merge branch 'feature/add_category_collection_generators' into develop (2 days ago) 
ee235d6 - add category collection models (2 days ago) 

Upvotes: 2

Views: 99

Answers (2)

Dralagen
Dralagen

Reputation: 51

You can just reformat output with just short hash and subject

git log --oneline --pretty="format:%h - %s"

Upvotes: 0

VonC
VonC

Reputation: 1323115

You can check if changing the setting log.date changes your log date display:

log.date

Set the default date-time mode for the log command.
Setting a value for log.date is similar to using git log's --date option.

Possible values are

  • relative,
  • local,
  • default,
  • iso,
  • rfc, and
  • short

Try for example:

git config log.date short

The goal, of course, is to keep using git log, not git log with options, and a git log alias.

Upvotes: 1

Related Questions