Skip to content

Instantly share code, notes, and snippets.

@GreatBahram
Created November 16, 2019 10:59
Show Gist options
  • Save GreatBahram/c36773c66758f18a4aa5f210fb3053fc to your computer and use it in GitHub Desktop.
Save GreatBahram/c36773c66758f18a4aa5f210fb3053fc to your computer and use it in GitHub Desktop.
Get different information about program on debian os
# Get list of available packages on your operating system
dpkg --get-selections
# To check whether a package is installed or not:
get --get-selections {prg_name}
# Search for a filename comes from which package
dpkg -S `which ifconfig`
# List files installed to your system from package-name.
dpkg --listfiles/-L {pkg_name}
# List contents of a deb package.
dpkg --contents/-C foo.deb
# Find all dependencies of a package
apt-cache depends foo.deb
# List different version of a pacakge on repo
apt-cache policy foo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment