mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 13:22:48 +00:00
Various cleanup to run_command
* Rename fail_on_rc_non_zero to check_rc, much more succinct. * Simplify method defintion * Fix command module and drop shell=shell option; whether to use shell is determined by if args is a list.
This commit is contained in:
@@ -99,7 +99,7 @@ def main():
|
||||
args = shlex.split(args)
|
||||
startd = datetime.datetime.now()
|
||||
|
||||
rc, out, err = module.run_command(args, shell=shell, executable=executable)
|
||||
rc, out, err = module.run_command(args, executable=executable)
|
||||
|
||||
endd = datetime.datetime.now()
|
||||
delta = endd - startd
|
||||
|
||||
Reference in New Issue
Block a user