[a] Add package preview
This commit is contained in:
parent
36c24fbdd5
commit
45fbd57302
|
@ -3,10 +3,10 @@
|
|||
GUI scripts for popular cli tools, based on dialog and fzf
|
||||
|
||||
## Scripts
|
||||
a - for managing apt packages
|
||||
g - for managing git repo
|
||||
s - for managing systemd services
|
||||
r - for running named commands from ~/.aliases.txt file
|
||||
- `a` - for managing apt packages
|
||||
- `g` - for managing git repo
|
||||
- `s` - for managing systemd services
|
||||
- `r` - for running named commands from ~/.aliases.txt file
|
||||
|
||||
## Installation
|
||||
Download .deb package from Releases, then install it
|
||||
|
|
2
a
2
a
|
@ -8,7 +8,7 @@ action=$(DIALOGRC=/tmp/.dialogrc dialog --stdout --erase-on-exit --menu "Choose
|
|||
|
||||
|
||||
if [[ $action == "Install" || $action == "Remove" ]]; then
|
||||
package=$(apt list 2>/dev/null | awk -F'/' 'NR>1{print $1}' | fzf)
|
||||
package=$(apt-cache search '' | sort | cut --delimiter ' ' --fields 1 | fzf --multi --cycle --reverse --preview 'apt-cache show {1}')
|
||||
sudo apt ${action,,} $package -y
|
||||
elif [[ $action == "Update" || $action == "Upgrade" ]]; then
|
||||
sudo apt ${action,,} -y
|
||||
|
|
Loading…
Reference in New Issue