summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYaroslav Halchenko <debian@onerussian.com>2012-12-20 14:34:56 -0500
committerYaroslav Halchenko <debian@onerussian.com>2012-12-20 14:34:56 -0500
commit751f9839f15e1b40c42caacd9764dcef1d3f9e23 (patch)
tree0069f7cf4d553ad24e4d8986abbb5d6f6ea3bce7
parentc0bc7e854f779ba17e08edffbf414a78755f4f83 (diff)
downloadcython-751f9839f15e1b40c42caacd9764dcef1d3f9e23.tar.gz
BF: replace show-ref with rev-parse --verify for determining current commit
git show-ref -s HEAD has shown to not work in all scenarios and git rev-parse --help provides this as an ultimate example: ยท Print the object name of the current commit: $ git rev-parse --verify HEAD
-rw-r--r--setup.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/setup.py b/setup.py
index 7b605ddc4..5bce5d9d2 100644
--- a/setup.py
+++ b/setup.py
@@ -27,7 +27,7 @@ class sdist(sdist_orig):
self.force_manifest = 1
if (sys.platform != "win32" and
os.path.isdir('.git')):
- assert os.system("git show-ref -s HEAD > .gitrev") == 0
+ assert os.system("git rev-parse --verify HEAD > .gitrev") == 0
sdist_orig.run(self)
add_command_class('sdist', sdist)