xbps

Look for cowsay in the repository:

1xbps-query --repository --search cowsay

Short version:

1xbps-query -Rs cowsay

Search with regex:

1xbps-query --regex -Rs 'cow(s)?\w'

xbps searches

List what's required for cowsay

1xbps-query -x cowsay

What packages are orphaned (i.e. installed as a dependency for another package, which has since been removed)?

1xbps-query -O

Show cowsay's dependencies.

1xbps-query -x cowsay

This shows perl. To see what else depends on perl:

1xbps-query -X perl

List all manually installed software.

1xbps-query -m

Install

Install cowsay

1xbps-install cowsay

Upgrade current packages. -R looks at repositories, -s makes a sloppy search (for rough matches).

1xbps-install -Suv

xbps searches

Remove/ Uninstall

Remove cowsay

1xbps-remove cowsay

...and all dependencies

1xbps-remove -R cowsay

Remove all orphaned dependencies.

1xbps-remove -o

Show information about cowsay

xbps searches

Fixes

Reinstall cowsay

1xbps-install -f cowsay

Look for broken packages.

1sudo xbps-pkgdb -a

And if you've found any, you might reconfigure all packages forcefully:

1sudo xbps-reconfigure -af