Created
April 30, 2018 15:05
-
-
Save mekhami/a193487a5a352741daa7000cfc519f1b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def mutate(root, info, name=None, desc=None, cmd=None, tags=None, task_files=None): | |
try: | |
task_dict = {} | |
if name: | |
task_dict['name'] = name | |
if desc: | |
task_dict['desc'] = desc | |
if cmd: | |
task_dict['cmd'] = cmd | |
if tags: | |
task_dict['tags'] = tags | |
if task_files: | |
task_dict['task_files'] = task_files | |
task = pipeline_api.update_task(args.get('uuid'), return_dict=False, agent=info.context['agent'], **task_dict) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment