macOS: Generate correct framework and Info.plist version numbers (issue #1969)

This commit is contained in:
Marshall Greenblatt
2017-02-06 18:15:42 -05:00
parent fda2f34c75
commit aa398d8798
2 changed files with 57 additions and 9 deletions

View File

@@ -11,7 +11,11 @@ if __name__ != "__main__":
sys.stderr.write('This file cannot be loaded as a module!')
sys.exit()
if git.is_checkout('.'):
sys.stdout.write(git.get_commit_number())
if len(sys.argv) < 2:
raise Exception('Path expected on command-line')
path = sys.argv[1]
if git.is_checkout(path):
sys.stdout.write(git.get_commit_number(path))
else:
raise Exception('Not a valid checkout')
raise Exception('Not a valid checkout: ' + path)