diff options
Diffstat (limited to 'gn/codesign_ios.py')
-rw-r--r-- | gn/codesign_ios.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/gn/codesign_ios.py b/gn/codesign_ios.py index 66a97d39ee..beb3603b04 100644 --- a/gn/codesign_ios.py +++ b/gn/codesign_ios.py @@ -16,12 +16,14 @@ import tempfile # Arguments to the script: # pkg path to application directory, e.g. out/Debug/dm.app # executable and plist should already be in this directory -pkg, = sys.argv[1:] +# identstr search string (regex fragment) for code signing identity +# profile name of provisioning profile +pkg,identstr,profile = sys.argv[1:] # Find the Google signing identity. identity = None for line in subprocess.check_output(['security', 'find-identity']).split('\n'): - m = re.match(r'''.*\) (.*) ".*Google.*"''', line) + m = re.match(r'''.*\) (.*) "''' + identstr + '"', line) if m: identity = m.group(1) assert identity @@ -31,7 +33,7 @@ mobileprovision = None for p in glob.glob(os.path.join(os.environ['HOME'], 'Library', 'MobileDevice', 'Provisioning Profiles', '*.mobileprovision')): if re.search(r'''<key>Name</key> -\t<string>Google Development</string>''', open(p).read(), re.MULTILINE): +\t<string>''' + profile + r'''</string>''', open(p).read(), re.MULTILINE): mobileprovision = p assert mobileprovision |