mirror of
https://github.com/daylinmorgan/viv.git
synced 2024-12-22 02:30:44 -06:00
fix: use correct name in validate script
This commit is contained in:
parent
696a512a78
commit
5eb67be353
1 changed files with 4 additions and 3 deletions
|
@ -52,7 +52,7 @@ from typing import (
|
||||||
Union,
|
Union,
|
||||||
)
|
)
|
||||||
|
|
||||||
__version__ = "23.8b2-17-g495ac80-dev"
|
__version__ = "23.8b2-18-g696a512-dev"
|
||||||
|
|
||||||
|
|
||||||
class Spinner:
|
class Spinner:
|
||||||
|
@ -1727,6 +1727,7 @@ class Viv:
|
||||||
viv shim black
|
viv shim black
|
||||||
viv shim yartsu -o ~/bin/yartsu --standalone
|
viv shim yartsu -o ~/bin/yartsu --standalone
|
||||||
"""
|
"""
|
||||||
|
|
||||||
default_bin, bin = self._pick_bin(reqs, bin)
|
default_bin, bin = self._pick_bin(reqs, bin)
|
||||||
output = Env().viv_bin_dir / default_bin if not output else output.absolute()
|
output = Env().viv_bin_dir / default_bin if not output else output.absolute()
|
||||||
|
|
||||||
|
@ -2057,7 +2058,7 @@ class Cli:
|
||||||
self.parsers[grp].add_argument(*arg.args, **arg.kwargs)
|
self.parsers[grp].add_argument(*arg.args, **arg.kwargs)
|
||||||
|
|
||||||
def _validate_args(self, args: Namespace) -> None:
|
def _validate_args(self, args: Namespace) -> None:
|
||||||
name = args.func.__name__
|
name = args.func.__name__.replace("cmd_", "")
|
||||||
if name in ("freeze", "shim"):
|
if name in ("freeze", "shim"):
|
||||||
if not args.reqs:
|
if not args.reqs:
|
||||||
error("must specify a requirement")
|
error("must specify a requirement")
|
||||||
|
@ -2097,7 +2098,7 @@ class Cli:
|
||||||
+ " shouldn't be used with a git-based installation",
|
+ " shouldn't be used with a git-based installation",
|
||||||
)
|
)
|
||||||
|
|
||||||
if name == "run":
|
if name in ("run", "shim"):
|
||||||
if not (args.reqs or args.script):
|
if not (args.reqs or args.script):
|
||||||
error("must specify a requirement or --script")
|
error("must specify a requirement or --script")
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue