Skip to content

Commit 0a5703f

Browse files
committed
Improved yeet to behave more like pacman and its wrappers
1 parent 9e1d1c5 commit 0a5703f

1 file changed

Lines changed: 10 additions & 1 deletion

File tree

rc/shell/functions

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,16 @@ function package_manager_command() {
4343
local PACKAGE_MANAGER_COMMAND
4444
local PACKAGE_MANAGER_FAMILY
4545

46-
OPERATION="${1}" && shift
46+
case "${1}" in
47+
install|search|uninstall|update|upgrade|-* )
48+
OPERATION="${1}"
49+
shift
50+
;;
51+
*)
52+
OPERATION='search'
53+
;;
54+
esac
55+
4756
PACKAGE_MANAGER='unknown'
4857
PACKAGE_MANAGER_COMMAND='unknown'
4958
PACKAGE_MANAGER_FAMILY='unknown'

0 commit comments

Comments
 (0)