summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefano Pigozzi <stefano.pigozzi@gmail.com>2016-01-05 12:24:50 +0100
committerStefano Pigozzi <stefano.pigozzi@gmail.com>2016-01-05 12:27:04 +0100
commit0015afd059926d966f145f4410d3f09415c83535 (patch)
tree9b5d0745fe5d79a582e6585a6aadf174061bce9e
parentd0cd7fa31b1812c273f938cb4fd5ecf7fc9eec79 (diff)
downloadmpv-0015afd059926d966f145f4410d3f09415c83535.tar.bz2
mpv-0015afd059926d966f145f4410d3f09415c83535.tar.xz
bundle: remove git sha from the Info.plist version
Fixes #2677
-rwxr-xr-xTOOLS/osxbundle.py11
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)