Interactive mode takes a configchannel without -c switch, so allow this format to be valid also for non-interactive mode (similar to other commands), original -c syntax is unchanged. --- spacecmd/src/lib/configchannel.py | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/spacecmd/src/lib/configchannel.py b/spacecmd/src/lib/configchannel.py index fcb9687..884a138 100644 --- a/spacecmd/src/lib/configchannel.py +++ b/spacecmd/src/lib/configchannel.py @@ -544,6 +544,12 @@ def do_configchannel_addfile(self, args, update_path=''): contents = editor(template = template, delete = True) else: + # the channel name can be passed in without -c + if len(args): + options.channel = args[0] + + logging.debug("Using channel %s" % options.channel) + if not options.path: logging.error('The path is required') return -- 1.7.1 _______________________________________________ Spacewalk-devel mailing list Spacewalk-devel@redhat.com https://www.redhat.com/mailman/listinfo/spacewalk-devel