I want to check a package's license before installing with apt and flatpak.
This would be particularly useful in PPAs / custom repositories that allow non-FLOSS licenses, and may have non-FLOSS dependencies too.
It has to be possible, since Discover can apparently do it, at least for official packages (though maybe it's impossible for custom repos, since they aren't on Launchpad?). At least Flathub does have license info on package's pages.
But I want to check it via command-line.
snap info $PKG_NAMEcan be used to check license of uninstalled snap packages - OK
apt info $PKG_NAME/
apt-cache show $PKG_NAMEdoesn't (always?) have license information
flatpak info $PKG_IDonly works for installed packages
flatpak search $PKG_NAME -vvtook way too long to show basically no information
Ideally there should be an easy way to check privacy policies too, but I suppose that's asking too much...
- How to get to know the information about a package before installation in terminal
apt infodon't seem to have license information
- How do you find the licenses for everything installed on your system?
How do I find out the license for each of my installed applications/packages?
These seem to be only for packages already installed, but I want to check it before installation.