Skip to content

Commit

Permalink
Merge pull request tensorflow#4580 from Phhere/patch-1
Browse files Browse the repository at this point in the history
Support older versions of git
  • Loading branch information
drpngx authored Oct 26, 2016
2 parents 7ba17e2 + e1ba779 commit 7de3419
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tensorflow/tools/git/gen_git_source.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ def get_git_version(git_base_path):
"""
unknown_label = b"unknown"
try:
val = subprocess.check_output(["git", "-C", git_base_path, "describe",
val = subprocess.check_output(["git", str("--git-dir="+git_base_path+"/.git"), str("--work-tree="+git_base_path), "describe",
"--long", "--dirty", "--tags"]).strip()
return val if val else unknown_label
except subprocess.CalledProcessError:
Expand Down

0 comments on commit 7de3419

Please sign in to comment.