From: Derrick Stolee <derrickstolee@github.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Victoria Dye via GitGitGadget <gitgitgadget@gmail.com>,
git@vger.kernel.org, reichemn@icloud.com,
Victoria Dye <vdye@github.com>
Subject: Re: [PATCH v2] mv: refresh stat info for moved entry
Date: Tue, 29 Mar 2022 14:54:57 -0400 [thread overview]
Message-ID: <d017b0c6-c06b-e8cd-55a1-6972a9ae7c52@github.com> (raw)
In-Reply-To: <xmqqa6d8wvwt.fsf@gitster.g>
On 3/29/2022 12:44 PM, Junio C Hamano wrote:
> Derrick Stolee <derrickstolee@github.com> writes:
>
>>> Note that the test added in 't7001-mv.sh' requires a "sleep 1" to ensure the
>>> 'ctime' of the file creation will be definitively older than the 'ctime' of
>>> the renamed file in 'git mv'.
>>
>> Unfortunate that this is necessary, but it seems to be the only way
>> to handle this because of the interaction with the system clock and
>> the filesystem. There are several sleeps like this in
>> t1701-racy-split-index.sh, for example.
>
> Does "test-tool chmtime" to tweak the filesystem timestamp help? I
> didn't look at the specific step that uses sleep to work around.
The issue here is related to ctime, which is not modified by that
helper. It also uses utime() which does not seem to have a way to
modify ctime (which makes sense).
Thanks,
-Stolee
next prev parent reply other threads:[~2022-03-29 18:55 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-25 1:56 [PATCH] mv: refresh stat info for moved entry Victoria Dye via GitGitGadget
2022-03-25 14:31 ` Derrick Stolee
2022-03-25 22:37 ` Victoria Dye
2022-03-25 23:29 ` Junio C Hamano
2022-03-26 1:23 ` Victoria Dye
2022-03-29 1:07 ` [PATCH v2] " Victoria Dye via GitGitGadget
2022-03-29 13:19 ` Derrick Stolee
2022-03-29 16:44 ` Junio C Hamano
2022-03-29 18:54 ` Derrick Stolee [this message]
2022-03-29 19:05 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d017b0c6-c06b-e8cd-55a1-6972a9ae7c52@github.com \
--to=derrickstolee@github.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=gitster@pobox.com \
--cc=reichemn@icloud.com \
--cc=vdye@github.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).