Manjaro-Pek / pacli

A simple and interative Bash Frontend for Pacman/Yaourt/Pacaur
GNU General Public License v2.0
44 stars 8 forks source link

update "list local files" option #44

Closed excalibur1234 closed 5 years ago

excalibur1234 commented 8 years ago

i tried to update this option with the following code, but i do not know how to do it:

    # use fzf to ask the user to select an installed package. the package name gets save in variable "pkg"
    pkg=$(pacman -Qq | fzf -e +s -i -0 --cycle --reverse --margin=4%,1%,1%,2% --inline-info --header="Cancel list selection with CTRL+C or ESC" --prompt='Search and select package > ')

    # take the output of command "pacman -Qlq ${pkg}" and make it searchable with fzf. for all used fzf flags see "man fzf". store all marked lines in file /tmp/pacli-list.
    pacman -Qlq ${pkg} --color always | fzf -m -e +s -i -q /usr/bin/ --reverse --margin=4%,1%,1%,1% --inline-info --header="List of files of package \"${pkg}\". Cancel lists selection with CTRL+C or ESC." --prompt='Enter one or more filter terms > ' >> /tmp/pacli-list

    unset pkg

using fzf to filter the output is especially useful for packages with a huge number of files.

excalibur1234 commented 5 years ago

i close my issue, not because it is solved, but because pacli is abandoned and this issue is probably never getting fixed.

this and many other issues are already fixed in a successor to pacli called pacui: https://github.com/excalibur1234/pacui