VideosMy ProjectsProgramming BlogGallery
  1. Home
  2. Blog
  3. How to find a files age in git
Programming Blog

Atom/RSS Feed

git

How to find a files age in git

git

You can find a files age using the git log command. As seen below

git log --diff-filter=A --follow <file>

For Example

git log --diff-filter=A --follow README.md

How it works

  • --diff-filter=A filters only added files
  • --follow follows the file through any renames it has had
Join my mailing list