Skip to content

Commit

Permalink
feat(build): Add Git archives version files (deepmodeling#3669)
Browse files Browse the repository at this point in the history
When downloading the source code of a branch or a release from GitHub or
the mirror, there is no Git version information, making setuptools-scm
unable to read the version. The alternative way is to add a git archive
file supported by setuptools-scm. See:
* https://setuptools-scm.readthedocs.io/en/latest/usage/#git-archives
(available in setuptools-scm 7.0.0)
*
https://git-scm.com/docs/git-archive#Documentation/git-archive.txt-export-subst
*
https://docs.github.com/en/repositories/working-with-files/using-files/downloading-source-code-archives

Generated by the task: njzjz-bot/njzjz-bot#4.
  • Loading branch information
njzjz-bot authored Apr 13, 2024
1 parent a26b680 commit 3eb3d51
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .git_archival.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
node: $Format:%H$
node-date: $Format:%cI$
describe-name: $Format:%(describe:tags=true,match=*[0-9]*)$
ref-names: $Format:%D$
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# do not show up detailed difference on GitHub
source/3rdparty/* linguist-generated=true
source/3rdparty/README.md linguist-generated=false
.git_archival.txt export-subst

0 comments on commit 3eb3d51

Please sign in to comment.