📦 Make Git archives reproducible (#1338)

Some time ago, it was discovered that Git archives having
`ref-names: $Format:%D$` in `.git_archival.txt` may change when
references existing in the repository change over time [[1]]. This
means that downloading an archive for a commit from an immutable URL
may start yielding slightly different results. This hurts the ability
of downstreams to source projects from Git archive URLs.

With that in mind, modern `setuptools-scm` advises against having this
entry in the `.git_archival.txt` template [[2]]. And this patch
implements said recommendation.

[1]: https://github.com/pypa/setuptools_scm/issues/806
[2]: https://setuptools-scm.readthedocs.io/en/latest/usage/#git-archives
This commit is contained in:
Sviatoslav Sydorenko (Святослав Сидоренко) 2024-08-24 07:13:16 +02:00 committed by GitHub
parent 31db9c781d
commit da2333cd37
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 0 additions and 1 deletions

View File

@ -1,4 +1,3 @@
node: $Format:%H$
node-date: $Format:%cI$
describe-name: $Format:%(describe:tags=true,match=*[0-9]*)$
ref-names: $Format:%D$