New tool: stampdalf - A filesystem timestamp preservation tool
David A. Wheeler
dwheeler at dwheeler.com
Thu Dec 18 16:57:21 UTC 2025
> On Dec 18, 2025, at 2:31 AM, Luca Di Maio <luca.dimaio1 at gmail.com> wrote:
>
> Hi all,
>
> I would like to introduce a new tool I have developed that may be of
> interest to this community: stampdalf.
>
> Repository: https://github.com/89luca89/stampdalf
>
> stampdalf is a simple command-line utility written in Go that wraps
> arbitrary commands and ensures filesystem timestamp reproducibility.
>
> The tool addresses a common challenge in reproducible builds: commands
> that modify files often update their access and modification times as a
> side effect, even when the actual content remains unchanged or is
> modified in a reproducible way (for example idempotent commands). This
> can lead to non-reproducible build artifacts.
>
> How it works:
>
> - Before executing the wrapped command, stampdalf scans the target
> directory tree and records all file timestamps (atime/mtime)
> - The specified command is then executed normally.
> - After command completion, stampdalf restores the original timestamps
> for all pre-existing files. Any newly created files are set to Unix
> epoch by default, or to SOURCE_DATE_EPOCH if the environment variable
> is set.
Does it (1) *unilaterally* reset all original timestamps, or (2) only reset timestamps
of pre-existing files that have the *same* contents (e.g., same length & cryptographic hash)?
It's the option #2 that I want.
Thanks!
--- David A. Wheeler
More information about the rb-general
mailing list