GIT-UTIMES(1)
π git-utimes(1) β the Git Extras glow-up for your mtimes
okay bestie, so you know how git files be sitting there with modification times that make zero sense? like they got touched at 3am on a Tuesday for no reason? yeah. this is the fix. it's git-utimes, it lives in Git Extras, and it's lowkey iconic. π¦
β¨ NAME β¨
git-utimes β change files modification time to their last commit date π°οΈπ
literally what it says on the tin. no cap.
πΈ SYNOPSIS πΈ
git-utimes [--newer]
that's it. that's the whole vibe. one optional flag, zero drama. π
π§ DESCRIPTION π§
so here's the tea: git-utimes goes through your files and sets each one's modification time to the date of its last commit. your filesystem timestamps finally match reality. slay. β¨
and the super important part β the way that it's not out here messing with everything β it does not touch files that are in the working tree or index. nope. those get left all the way alone. π
so if you've got uncommitted edits flopping around in your working tree or staged in the index, chill, this command is not coming for them. π«Ά
π OPTIONS π
--newerβ this one preserves the original modification time of files that were committed from the local repo. how? by only touching files that are newer than their last commit date. it's giving "respectful." it's giving "boundaries." we love her. π
π₯ EXAMPLES π₯
1. update all files' modification time to their last commit date, except those in working tree or index:
$ git utimes
the classic. the standard. the main character move. π
2. same as above, but preserve the original modification time of files that were committed from the local repo:
$ git utimes --newer
same energy, but with the --newer flag doing its little protective thing β¨
π AUTHOR π
written by Vitaly Chikunov <vt@altlinux.org>, inspired by Stackexchange comments. (iykyk π)
updated by Bill Wood <wpwoodjr@gmail.com> to add the --newer flag and ignore files in the working tree or index. π«Ά
π REPORTING BUGS π
found a bug? bestie, tell the people:
<https://github.com/tj/git-extras/issues>
π SEE ALSO π
<https://github.com/tj/git-extras>
and that's the whole page, periodt. π this gem of a manpage is straight out of Git Extras, dated May 2026, and filed under GIT-UTIMES(1) β go forth and fix those timestamps, you absolute icon. πβ¨
π¦ where this page comes from
- ubuntu stonking: git-extras 7.5.0-1 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms