[Git][reproducible-builds/reproducible-website][master] note on using `git archive`

Arnout Engelen (@raboof-guest) gitlab at salsa.debian.org
Wed Oct 8 12:16:12 UTC 2025



Arnout Engelen pushed to branch master at Reproducible Builds / reproducible-website


Commits:
6e4ced17 by Arnout Engelen at 2025-10-08T14:15:50+02:00
note on using `git archive`

- - - - -


1 changed file:

- _docs/archives.md


Changes:

=====================================
_docs/archives.md
=====================================
@@ -142,6 +142,16 @@ Zip files can additionally store metadata in "extra file attributes". We believe
 
 When creating `.zip` files, it is [recommended to use the `--no-extra` / `-X`](https://lists.reproducible-builds.org/pipermail/rb-general/2024-March/003283.html) argument to not save these fields. It is also recommended that [developers unzip archives with `TZ=UTC`](https://lists.reproducible-builds.org/pipermail/rb-general/2023-April/002927.html).
 
+`git archive`
+-------------
+
+[`git archive`](https://git-scm.com/docs/git-archive) does
+[not guarantee](https://lists.reproducible-builds.org/pipermail/rb-general/2022-October/002712.html)
+deterministic output. It uses the commit time as recorded in the
+referenced commit object when used with a commit ID or tag ID (but
+not when given a tree ID). In practice, the `tar` output is typically
+stable, but the internal `gzip` implementation is not. Using
+`git archive --format=tar TAG | gzip -6 -n` is more reliable.
 
 Post-processing
 ---------------



View it on GitLab: https://salsa.debian.org/reproducible-builds/reproducible-website/-/commit/6e4ced171dc4558c7e6f6650cf674ddd00f561b1

-- 
View it on GitLab: https://salsa.debian.org/reproducible-builds/reproducible-website/-/commit/6e4ced171dc4558c7e6f6650cf674ddd00f561b1
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.reproducible-builds.org/pipermail/rb-commits/attachments/20251008/4eb930fa/attachment.htm>


More information about the rb-commits mailing list