added function providefiles

list files provided by package
This commit is contained in:
Bryan Joshua Pedini 2024-08-01 02:02:52 +02:00
parent 7b3de6cef0
commit 8b23dc96a3

40
pman.sh
View File

@ -64,6 +64,15 @@ case "$command_args" in
su_needed=false su_needed=false
command_args="-F" command_args="-F"
;; ;;
"providefiles")
# Update the cache
su_needed=true
command_args="-Fy"
execute_command "${@}"
su_needed=false
command_args="-Fl"
;;
"installed") "installed")
command_args="-Q" command_args="-Q"
;; ;;
@ -112,22 +121,23 @@ case "$command_args" in
echo echo
echo "Usage: pman <command> [args...]" echo "Usage: pman <command> [args...]"
echo "Available commands:" echo "Available commands:"
echo " yay (aur) - yay | invoke yay " echo " yay (aur) - yay | invoke yay "
echo " (aur packages - all the normal operations except config are available)" echo " (aur packages - all the normal operations except config are available)"
echo " aur (yay) - yay | same as \"yay\"" echo " aur (yay) - yay | same as \"yay\""
echo " search - pacman -Ss | search packages" echo " search - pacman -Ss | search packages"
echo " info - pacman -Si | show package information" echo " info - pacman -Si | show package information"
echo " localinfo - pacman -Qi | show local package information" echo " localinfo - pacman -Qi | show local package information"
echo " provides - pacman -F | list packages that provide file" echo " provides - pacman -F | list packages that provide file"
echo " installed - pacman -Q | list installed packages" echo " providefiles - pacman -Fl | list files provided by package"
echo " install - pacman -S | install packages" echo " installed - pacman -Q | list installed packages"
echo " update - pacman -Sy | updates the repositories" echo " install - pacman -S | install packages"
echo " upgradable - pacman -Qu | list available upgrades" echo " update - pacman -Sy | updates the repositories"
echo " upgrade - pacman -Syu | upgrades your system" echo " upgradable - pacman -Qu | list available upgrades"
echo " remove - pacman -Rs | remove packages & dependencies" echo " upgrade - pacman -Syu | upgrades your system"
echo " purge - pacman -Rns | remove packages, dependencies & conf" echo " remove - pacman -Rs | remove packages & dependencies"
echo " clean - pacman -Scc | remove all package files & trash" echo " purge - pacman -Rns | remove packages, dependencies & conf"
echo " config - /etc/pacman.conf | edits pacman configuration" echo " clean - pacman -Scc | remove all package files & trash"
echo " config - /etc/pacman.conf | edits pacman configuration"
exit 1 exit 1
fi fi
;; ;;