tj / tj/git-extras

`git-utimes` desired behaviour for directories

Open
#1,246 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Shell
Stars
18.1k
Forks
1.2k
Avg merge
5d 17h
Merged PRs (30d)
1

Description

Hello, I have a question regarding the desired behaviour for git-utimes and directories.

We had an environment running with git 2.30.2-1 (bullseye) and updated to 2.39.5-0 (bookworm).
Before the update directories and files were touched. After the update only files are touched.
This was with version 6.4.0 of git-extras but 7.4.0 seems to affect only files as well. I therefore think this is due a change in git itself.

As git does not track directories this is technically correct.
We would still like to have the timestamps of the directories to be updated.

My question is what the desired default behaviour is and if you would accept a PR that adds this back in (maybe behind a flag if not default behaviour)?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the git-utimes command and checking how it currently handles files versus directories. Compare the reported behavior across the mentioned Git versions, then clarify whether directory timestamps should be restored by default or behind a flag; done means the behavior is agreed and consistently verified.

Written by the indexing model from the issue text.

Assessment

Tech stack
git, shell
Domain
cli
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.