X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=cdist;h=7a5748bf9d9d83c7a2cbd5816ecccbb84bc6b12a;hb=18f68015a5e32e88bca5c7cb417092fdce1650b0;hp=516dcadaf34fe742fbc1291c4c76ce43b27884bb;hpb=d0d369e34fa1767889ec817315e909c2db081ad9;p=cdist.git diff --git a/cdist b/cdist index 516dcad..7a5748b 100755 --- a/cdist +++ b/cdist @@ -257,11 +257,11 @@ def rmtree(a): def command(c): log_normal(c) try: - r = subprocess.run(shlex.split(c), shell=True) + r = subprocess.run(c, shell=True) if r.returncode != 0: - raise Error(f'command {c} failed ({r.returncode})') + raise Error('command %s failed (%d)' % (c, r.returncode)) except Exception as e: - raise Error(f'command {c} failed ({e})') + raise Error('command %s failed (%s)' % (c, e)) def command_and_read(c): log_normal(c) @@ -755,6 +755,9 @@ def notarize(dmg, bundle_id): elif status == 'success': subprocess.run(['xcrun', 'stapler', 'staple', dmg]) return + else: + print("Could not understand xcrun response") + print(p) time.sleep(30) raise Error("Notarization timed out")