Mercurial > libervia-backend
comparison frontends/src/jp/cmd_shell.py @ 2317:f4e05600577b
jp (arg_tools): args is not modified anymore in get_use_args + fixed args returned + parser_args are returned separatly (return is now a tuple)
author | Goffi <goffi@goffi.org> |
---|---|
date | Sat, 08 Jul 2017 22:49:55 +0200 |
parents | 8d9bd5d77336 |
children | 5129a0506739 |
comparison
equal
deleted
inserted
replaced
2316:7b448ac50a69 | 2317:f4e05600577b |
---|---|
180 def do_do(self, args): | 180 def do_do(self, args): |
181 """lauch a command""" | 181 """lauch a command""" |
182 args = self.parse_args(args) | 182 args = self.parse_args(args) |
183 # args may be modified by use_args | 183 # args may be modified by use_args |
184 # to remove subparsers from it | 184 # to remove subparsers from it |
185 use_args = arg_tools.get_use_args(self.host, | 185 parser_args, use_args = arg_tools.get_use_args(self.host, |
186 args, | 186 args, |
187 self.use, | 187 self.use, |
188 verbose=self.verbose, | 188 verbose=self.verbose, |
189 parser=self._cur_parser | 189 parser=self._cur_parser |
190 ) | 190 ) |
191 cmd_args = self.path + use_args + args | 191 cmd_args = self.path + parser_args + use_args |
192 self.run_cmd(cmd_args) | 192 self.run_cmd(cmd_args) |
193 | 193 |
194 def do_use(self, args): | 194 def do_use(self, args): |
195 """fix an argument""" | 195 """fix an argument""" |
196 args = self.parse_args(args) | 196 args = self.parse_args(args) |