Pass settings to the rules

This commit is contained in:
nvbn
2015-04-08 21:08:35 +02:00
parent 173a4300b4
commit 9ed022d67f
8 changed files with 50 additions and 47 deletions
+2 -2
View File
@@ -1,7 +1,7 @@
def match(command):
def match(command, settings):
return ('permission denied' in command.stderr.lower()
or 'EACCES' in command.stderr)
def get_new_command(command):
def get_new_command(command, settings):
return 'sudo {}'.format(command.script)