0
0
mirror of https://github.com/mpv-player/mpv.git synced 2024-09-20 03:52:22 +02:00

bundle: remove git sha from the Info.plist version

Fixes #2677
This commit is contained in:
Stefano Pigozzi 2016-01-05 12:24:50 +01:00
parent d0cd7fa31b
commit 0015afd059

View File

@ -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)