mirror of
https://github.com/EeeeKa/webhook-catcher.git
synced 2025-09-23 19:32:09 +05:00
Fix actions with args
This commit is contained in:
parent
6575125224
commit
23d54b75e4
@ -383,7 +383,7 @@ class WebHookWorker(object):
|
||||
|
||||
@classmethod
|
||||
def do_action(cls, repo):
|
||||
result = subprocess.run(repo['action'], stdout=subprocess.PIPE, stderr=subprocess.PIPE, universal_newlines=True)
|
||||
result = subprocess.run(repo['action'].split(' '), stdout=subprocess.PIPE, stderr=subprocess.PIPE, universal_newlines=True)
|
||||
|
||||
return result
|
||||
|
||||
@ -487,7 +487,7 @@ def prepare_repos(repos, self_update_repo):
|
||||
if (not 'action' in repo) or (repo['action'] == ''):
|
||||
repo['action'] = ''
|
||||
else:
|
||||
action_file = repo['action'].split(' -')[0]
|
||||
action_file = repo['action'].split(' ')[0]
|
||||
if not (os.path.isfile(action_file) and os.access(action_file, os.X_OK)):
|
||||
pm('ERROR: Defined action file "{}" in repo "{}" not found or not executable.'.format(action_file, repo['name']))
|
||||
exit(4)
|
||||
|
Loading…
Reference in New Issue
Block a user