diff options
author | Stefano Pigozzi <stefano.pigozzi@gmail.com> | 2016-01-05 12:24:50 +0100 |
---|---|---|
committer | Stefano Pigozzi <stefano.pigozzi@gmail.com> | 2016-01-05 12:27:04 +0100 |
commit | 0015afd059926d966f145f4410d3f09415c83535 (patch) | |
tree | 9b5d0745fe5d79a582e6585a6aadf174061bce9e /TOOLS/osxbundle.py | |
parent | d0cd7fa31b1812c273f938cb4fd5ecf7fc9eec79 (diff) | |
download | mpv-0015afd059926d966f145f4410d3f09415c83535.tar.bz2 mpv-0015afd059926d966f145f4410d3f09415c83535.tar.xz |
bundle: remove git sha from the Info.plist version
Fixes #2677
Diffstat (limited to 'TOOLS/osxbundle.py')
-rwxr-xr-x | TOOLS/osxbundle.py | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/TOOLS/osxbundle.py b/TOOLS/osxbundle.py index 3ad52cb003..e9ef8bc4de 100755 --- a/TOOLS/osxbundle.py +++ b/TOOLS/osxbundle.py @@ -39,8 +39,17 @@ def apply_plist_template(plist_file, version): for line in fileinput.input(plist_file, inplace=1): print (line.rstrip().replace('${VERSION}', version)) +def bundle_version(): + if os.path.exists('VERSION'): + x = open('VERSION') + version = x.read() + x.close() + else: + version = sh("./version.sh").strip() + return version + def main(): - version = sh("./version.sh").strip() + version = bundle_version().rstrip() usage = "usage: %prog [options] arg" parser = OptionParser(usage) |