Skip to content

Commit f96193e

Browse files
Fixed domain test failures caused by --target-command argument (#764)
1 parent f6c9fe2 commit f96193e

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

linodecli/__init__.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -108,14 +108,14 @@ def main(): # pylint: disable=too-many-branches,too-many-statements
108108
sys.exit(ExitCodes.ARGUMENT_ERROR)
109109

110110
if parsed.command in ("set-custom-alias", "remove-custom-alias"):
111-
if not parsed.target_command or not parsed.alias:
111+
if not parsed.alias_command or not parsed.alias:
112112
print(
113-
"Both --target-command and --alias must be provided.",
113+
"Both --alias-command and --alias must be provided.",
114114
file=sys.stderr,
115115
)
116116
sys.exit(ExitCodes.ARGUMENT_ERROR)
117117

118-
command = parsed.target_command
118+
command = parsed.alias_command
119119
alias = parsed.alias
120120

121121
if command not in cli.ops:

linodecli/arg_helpers.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,16 +68,14 @@ def register_args(parser: ArgumentParser) -> ArgumentParser:
6868
)
6969

7070
parser.add_argument(
71-
"--target-command",
72-
"-t",
71+
"--alias-command",
7372
nargs="?",
7473
type=str,
7574
help="The command to set or remove an alias for.",
7675
)
7776

7877
parser.add_argument(
7978
"--alias",
80-
"-a",
8179
nargs="?",
8280
type=str,
8381
help="The alias to set or remove.",

0 commit comments

Comments
 (0)