Skip to content

FIX: old GIT (<1.7.2) does not know about --count flag#306

Merged
effigies merged 4 commits intopython-versioneer:masterfrom
foxtran:fix/old-git
Jul 21, 2022
Merged

FIX: old GIT (<1.7.2) does not know about --count flag#306
effigies merged 4 commits intopython-versioneer:masterfrom
foxtran:fix/old-git

Conversation

@foxtran
Copy link
Copy Markdown
Contributor

@foxtran foxtran commented Jul 21, 2022

Fixes #98, fixes #187.

--count flag comes from git v1.7.2 with commit git/git@f69c501

Note: I tried this PR on already-generated versioneer.py, I did not test that its generation is correct.

Comment thread src/git/from_vcs.py Outdated
Comment thread src/header.py Outdated
Copy link
Copy Markdown
Contributor

@effigies effigies left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Our mock runner needs to be updated now:

if args[0] == "rev-list":
return "42\n", 0

I would suggest something like:

                 if args[0] == "rev-list":
-                    return "42\n", 0
+                    return "hash\n" * 42, 0

Comment thread src/git/from_vcs.py Outdated
foxtran and others added 2 commits July 22, 2022 01:00
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
@effigies
Copy link
Copy Markdown
Contributor

Thanks!

@effigies effigies merged commit 492f844 into python-versioneer:master Jul 21, 2022
@foxtran
Copy link
Copy Markdown
Contributor Author

foxtran commented Jul 21, 2022

Thank you :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Error using old Git versions failure with git 1.7.1

2 participants