mirror of
https://gitlab.com/dslackw/slpkg.git
synced 2025-01-03 06:56:44 +01:00
Update positions arguments for tracking deps
This commit is contained in:
parent
61537e5451
commit
eeddc7ea82
1 changed files with 16 additions and 15 deletions
|
@ -362,21 +362,22 @@ class ArgParse(object):
|
|||
"--graph=",
|
||||
"--case-ins"
|
||||
]
|
||||
if (len(self.args) >= 3 and len(self.args) < 6 and
|
||||
self.args[0] in options):
|
||||
if self.args[1] in self.meta.repositories:
|
||||
for arg in self.args[3:]:
|
||||
if arg.startswith(additional_options[1]):
|
||||
flag.append(arg)
|
||||
arg = ""
|
||||
if arg in additional_options:
|
||||
flag.append(arg)
|
||||
if arg and arg not in additional_options:
|
||||
usage("")
|
||||
raise SystemExit()
|
||||
TrackingDeps(self.args[2], self.args[1], flag).run()
|
||||
else:
|
||||
usage(self.args[1])
|
||||
for arg in self.args:
|
||||
if arg.startswith(additional_options[1]):
|
||||
flag.append(arg)
|
||||
self.args.remove(arg)
|
||||
if arg in additional_options:
|
||||
flag.append(arg)
|
||||
# clean addition options from args
|
||||
for f in flag:
|
||||
if f in self.args:
|
||||
self.args.remove(f)
|
||||
if (len(self.args) >= 3 and self.args[0] in options and
|
||||
self.args[1] in self.meta.repositories):
|
||||
TrackingDeps(self.args[2], self.args[1], flag).run()
|
||||
elif (len(self.args) >= 2 and
|
||||
self.args[1] not in self.meta.repositories):
|
||||
usage(self.args[1])
|
||||
else:
|
||||
usage("")
|
||||
|
||||
|
|
Loading…
Reference in a new issue