[macOS] Update tccutil command

This commit is contained in:
Ivan Malison 2016-10-18 20:50:35 -07:00
parent 91264f659f
commit bc4b6be198
No known key found for this signature in database
GPG Key ID: 62530EFBE99DC2F8

View File

@ -115,10 +115,11 @@ SCRIPTS_NEEDING_ASSISTIVE_DEVICE_ACCESS = [
@ctask @ctask
def tccutil(ctx): def tccutil(ctx):
ctx.run('wget -O "$HOME/.lib/bin/tccutil.py" "https://raw.githubusercontent.com/IvanMalison/tccutil/master/tccutil.py"') if not os.path.exists(os.path.expanduser("~/.lib/bin/tccutil.py")):
ctx.run('chmod 755 "$HOME/.lib/bin/tccutil.py"') ctx.run('wget -O "$HOME/.lib/bin/tccutil.py" "https://raw.githubusercontent.com/IvanMalison/tccutil/master/tccutil.py"')
ctx.run('chmod 755 "$HOME/.lib/bin/tccutil.py"')
for script in SCRIPTS_NEEDING_ASSISTIVE_DEVICE_ACCESS: for script in SCRIPTS_NEEDING_ASSISTIVE_DEVICE_ACCESS:
command = 'sudo tccutil.py -i "{0}" && sudo tccutil.py -e "{0}"'.format(script) command = 'sudo tccutil.py -v -i "{0}" && sudo tccutil.py -v -e "{0}"'.format(script)
print(command) print(command)
ctx.run(command) ctx.run(command)