Skip to content

Commit

Permalink
Add kup update as alias for kup install (#128)
Browse files Browse the repository at this point in the history
Co-authored-by: Tamás Tóth <[email protected]>
  • Loading branch information
goodlyrottenapple and tothtamas28 authored Sep 12, 2024
1 parent f60bf14 commit 2ee30fe
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/kup/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -888,6 +888,14 @@ def main() -> None:
)
install.add_argument('-h', '--help', action=_HelpInstallAction)

update = subparser.add_parser(
'update',
help='update the stated package (alias of install)',
add_help=False,
parents=[verbose_arg, shared_args],
)
update.add_argument('-h', '--help', action=_HelpInstallAction)

uninstall = subparser.add_parser(
'uninstall', help="remove the given package from the user's PATH", parents=[verbose_arg]
)
Expand Down Expand Up @@ -966,7 +974,7 @@ def main() -> None:
if args.command == 'list':
list_package(package_name.base, args.inputs, args.status, args.version)

elif args.command == 'install':
elif args.command in ['install', 'update']:
install_package(package_name, args.version, args.override)
elif args.command == 'uninstall':
uninstall_package(package_name.base)
Expand Down

0 comments on commit 2ee30fe

Please sign in to comment.