Skip to content

Commit

Permalink
MAINT: Don't include "dirty" in versioneer generated versions.
Browse files Browse the repository at this point in the history
We patch the LICENSE file for both sdist and wheel releases, making them
all "dirty", i.e., containing files that have not been committed. Having
"dirty" in the product name is bad marketing and the versioneer tool
does not have an option or style that will omit that bit of information,
so patch the versioneer files to make that tag an empty string.
  • Loading branch information
charris authored and DimitriPapadopoulos committed Oct 15, 2022
1 parent b6d94fa commit 2145d9e
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion numpy/_version.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion tools/lint_diff.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
max_line_length = 79
statistics = True
ignore = E121,E122,E123,E125,E126,E127,E128,E226,E241,E251,E265,E266,E302,E402,E704,E712,E721,E731,E741,W291,W293,W391,W503,W504
exclude = numpy/__config__.py,numpy/typing/tests/data
exclude = versioneer.py,numpy/_version.py,numpy/__config__.py,numpy/typing/tests/data
4 changes: 2 additions & 2 deletions versioneer.py
Original file line number Diff line number Diff line change
Expand Up @@ -722,7 +722,7 @@ def git_pieces_from_vcs(tag_prefix, root, verbose, runner=run_command):
# if there is a tag matching tag_prefix, this yields TAG-NUM-gHEX[-dirty]
# if there isn't one, this yields HEX[-dirty] (no NUM)
describe_out, rc = runner(GITS, [
"describe", "--tags", "--dirty", "--always", "--long",
"describe", "--tags", "--dirty=", "--always", "--long",
"--match", f"{tag_prefix}[[:digit:]]*"
], cwd=root)
# --long was added in git-1.5.5
Expand Down Expand Up @@ -1244,7 +1244,7 @@ def git_pieces_from_vcs(tag_prefix, root, verbose, runner=run_command):
# if there is a tag matching tag_prefix, this yields TAG-NUM-gHEX[-dirty]
# if there isn't one, this yields HEX[-dirty] (no NUM)
describe_out, rc = runner(GITS, [
"describe", "--tags", "--dirty", "--always", "--long",
"describe", "--tags", "--dirty=", "--always", "--long",
"--match", f"{tag_prefix}[[:digit:]]*"
], cwd=root)
# --long was added in git-1.5.5
Expand Down

0 comments on commit 2145d9e

Please sign in to comment.