Package Management
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
Package management involves installing, updating, and removing software packages on a Linux system. This category includes tools specific to different Linux distributions, as well as universal package managers.
1 - Debian based
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
Debian-based package management systems use tools to handle software packages in .deb format. They provide a stable and secure environment with a focus on ease of use and reliability. Package management includes resolving dependencies, managing repositories, and ensuring system stability. Debian-based systems are known for their extensive software repositories and strong community support.
1.1 - 🖥️apt
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the apt command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# █████╗ ██████╗ ████████╗
# ██╔══██╗██╔══██╗╚══██╔══╝
# ███████║██████╔╝ ██║
# ██╔══██║██╔═══╝ ██║
# ██║ ██║██║ ██║
# ╚═╝ ╚═╝╚═╝ ╚═╝
# To search a package:
apt search package
# To show package informations:
apt show package
# To fetch package list:
apt update
# To download and install updates without installing new package:
apt upgrade
# To download and install the updates AND install new necessary packages:
apt dist-upgrade
# Full command:
apt update && apt dist-upgrade
# To install a new package(s):
apt install package(s)
# To uninstall package(s)
apt remove package(s)
# Packete liegen unter
/var/cache/apt/archives
#==============================##==============================#
# CMD APT #
#==============================##==============================#
# 15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian
################################################################################
# Find Location of Installed Package
apt content glances
# Check All Dependencies of a Package - This will help you to display raw information about dependencies of a particular package that you specify.
apt depends glances
# Search for a Package - The search option searches for the given package name and show all the matching packages.
apt search apache2
# View Information About Package - This will help you display information about package or packages, run the command below by specifying all the packages that you want to display information about.
apt show firefox
# Verify a Package for any Broken Dependencies - Sometimes during package installation, you may get errors concerning broken package dependencies, to check that you do not have these problems run the command below with the package name.
apt check firefox
# List Recommended Missing Packages of Given Package
apt recommends apache2
# Check Installed Package Version - The ‘version’ option will show you the installed package version.
apt version firefox
# Remove Unused Packages - When you install a new package on your system, it’s dependencies are also installed and they use some system libraries with other packages. The after removing that particular package, it’s dependencies will remain on the system, therefore to remove them use autoremove as follows:
apt autoremove
# Clean Old Repository of Downloaded Packages - The option ‘clean’ or ‘autoclean’ remove all old local repository of downloaded package files.
apt autoclean
or
apt clean
# Remove Packages with its Configuration Files - When you run apt with remove, it only removes the package files but configuration files remain on the system. Therefore to remove a package and it’s configuration files, you will have to use purge.
apt purge glances
# Install .Deb Package - To install a .deb file, run the command below with the filename as an argument as follows:
apt deb atom-amd64.deb
# Full upgrade
apt full-upgrade
#Using a single sudo to run multiple && arguments - Bashs here string
sudo -s <<< 'apt update -y && apt upgrade -y'
#Using a single sudo to run multiple && arguments
#This will also work with bash instead of sh shell sudo bash -c 'apt update -y && apt upgrade -y'
sudo sh -c 'apt update -y && apt upgrade -y'
# Get all upgradable deb packages in a single line - Works for debian and ubuntu based distros.
apt list --upgradable | grep -v 'Listing...' | cut -d/ -f1 | tr '\r\n' ' ' | sed '$s/ $/\n/'
# Sample output
# git-man git google-chrome-beta google-chrome-stable libnvidia-cfg1-430 libnvidia-common-430 libnvidia-compute-430 libnvidia-compute-430 libnvidia-decode-430 libnvidia-decode-430 libnvidia-encode-430 libnvidia-encode-430 libnvidia-fbc1-430 libnvidia-fbc1-430 libnvidia-gl-430 libnvidia-gl-430 libnvidia-ifr1-430 libnvidia-ifr1-430 libsmbclient libssh-4 libssh-gcrypt-4 libvulkan1 libvulkan1 libwbclient0 nvidia-compute-utils-430 nvidia-dkms-430 nvidia-driver-430
# nvidia-kernel-common-430 nvidia-kernel-source-430 nvidia-utils-430 opera-stable python3-samba samba-common-bin samba-common samba-libs smbclient thunderbird-gnome-support thunderbird-locale-en-us thunderbird-locale-en thunderbird winbind xserver-xorg-video-nvidia-430
# Using a single sudo to run multiple && arguments
sudo -s <<< 'apt update -y && apt upgrade -y'
# Using a single sudo to run multiple && arguments - Bash is here string
sudo -s <<< 'apt autoremove -y && apt autoclean -y'
# Write shell script without opening an editor - In this example, I’m creating a wrapper for apt-get that assumes yes every time — but the command could be anything.
sudo su -c "echo -e \"\x23\x21/usr/bin/sudo /bin/bash\napt-get -y \x24\x40\" > /usr/bin/apt-yes"
# Using a single sudo to run multiple && arguments - This will also work with bash instead of sh shell sudo bash -c 'apt update -y && apt upgrade -y'
sudo sh -c 'apt update -y && apt upgrade -y'
###########################
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command apt in a clear format. This allows users to quickly access the needed information for apt without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for apt are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
1.2 - 🖥️apt-cache
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the apt-cache command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
█████╗ ██████╗ ████████╗ ██████╗ █████╗ ██████╗██╗ ██╗███████╗
██╔══██╗██╔══██╗╚══██╔══╝ ██╔════╝██╔══██╗██╔════╝██║ ██║██╔════╝
███████║██████╔╝ ██║█████╗██║ ███████║██║ ███████║█████╗
██╔══██║██╔═══╝ ██║╚════╝██║ ██╔══██║██║ ██╔══██║██╔══╝
██║ ██║██║ ██║ ╚██████╗██║ ██║╚██████╗██║ ██║███████╗
╚═╝ ╚═╝╚═╝ ╚═╝ ╚═════╝╚═╝ ╚═╝ ╚═════╝╚═╝ ╚═╝╚══════╝
# To search for apt packages:
apt-cache search "whatever"
# To display package records for the named package(s):
apt-cache show pkg(s)
# To display reverse dependencies of a package
apt-cache rdepends package_name
# To display package versions, reverse dependencies and forward dependencies
# of a package
apt-cache showpkg package_name
#==============================##==============================#
apt-cache pkgnames
# To list all the available packages, type the following command.
apt-cache search vsftpd
# To find out the package name and with it description before installing, use the ‘search‘ flag. Using “search” with apt-cache will display a list of matched packages with short description. Let’s say you would like to find out description of package ‘vsftpd‘, then command would be.
apt-cache pkgnames vsftpd
# To find and list down all the packages starting with ‘vsftpd‘, you could use the following command.
apt-cache search nagios | awk ' { print $1}'
# Nach Paketen von Nagios suchen
apt-cache show netcat
# How Do I Check Package Information? - For example, if you would like to check information of package along with it short description say (version number, check sums, size, installed size, category etc). Use ‘show‘ sub command as shown below.
apt-cache showpkg vsftpd
# How Do I Check Dependencies for Specific Packages? - Use the ‘showpkg‘ sub command to check the dependencies for particular software packages. whether those dependencies packages are installed or not. For example, use the ‘showpkg‘ command along with package-name.
apt-cache stats
# How Do I Check statistics of Cache - The ‘stats‘ sub command will display overall statistics about the cache. For example, the following command will display Total package names is the number of packages have found in the cache.
#==============================##==============================#
# CMD APT-CACHE #
#==============================##==============================#
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command apt-cache in a clear format. This allows users to quickly access the needed information for apt-cache without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for apt-cache are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
1.3 - 🖥️apt-file
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the apt-file command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# █████╗ ██████╗ ████████╗ ███████╗██╗██╗ ███████╗
# ██╔══██╗██╔══██╗╚══██╔══╝ ██╔════╝██║██║ ██╔════╝
# ███████║██████╔╝ ██║█████╗█████╗ ██║██║ █████╗
# ██╔══██║██╔═══╝ ██║╚════╝██╔══╝ ██║██║ ██╔══╝
# ██║ ██║██║ ██║ ██║ ██║███████╗███████╗
# ╚═╝ ╚═╝╚═╝ ╚═╝ ╚═╝ ╚═╝╚══════╝╚══════╝
#
apt-file search /usr/bin/strings
# On Debian and derivatives, figure out what package you need to install to get the strings command. Use the usual full path (probably /usr/bin/something or /usr/sbin/something in most cases) to avoid large number of results.
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command apt-file in a clear format. This allows users to quickly access the needed information for apt-file without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for apt-file are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
1.4 - 🖥️apt-get
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the apt-get command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# █████╗ ██████╗ ████████╗ ██████╗ ███████╗████████╗
# ██╔══██╗██╔══██╗╚══██╔══╝ ██╔════╝ ██╔════╝╚══██╔══╝
# ███████║██████╔╝ ██║█████╗██║ ███╗█████╗ ██║
# ██╔══██║██╔═══╝ ██║╚════╝██║ ██║██╔══╝ ██║
# ██║ ██║██║ ██║ ╚██████╔╝███████╗ ██║
# ╚═╝ ╚═╝╚═╝ ╚═╝ ╚═════╝ ╚══════╝ ╚═╝
# Desc: Allows to update the operating system
# To fetch package list
apt-get update
# To download and install updates without installing new package.
apt-get upgrade
# To download and install the updates AND install new necessary packages
apt-get dist-upgrade
# Full command:
apt-get update && apt-get dist-upgrade
# To install a new package(s)
apt-get install package(s)
# Download a package without installing it. (The package will be downloaded in your current working dir)
apt-get download modsecurity-crs
# Change Cache dir and archive dir (where .deb are stored).
apt-get -o Dir::Cache="/path/to/destination/dir/" -o Dir::Cache::archives="./" install ...
# Show apt-get installed packages.
grep 'install ' /var/log/dpkg.log
# Silently keep old configuration during batch updates
apt-get update -o DPkg::Options::='--force-confold' ...
#==============================##==============================#
# CMD APT-GET Packetverwaltung #
#==============================##==============================#
apt-get install gpm
# installieren, um auch mit der Maus arbeiten zu können.
apt-get build-dep ffmpeg
# The below command will build the dependency, automatically during the corresponding package installation. Hence the process of package installation is very much fluent and easy.
apt-get update && apt-get install -qqy --force-yes openssh-server
# Install openssh-server
apt-get update
# How to Update System Packages - The ‘update‘ command is used to resynchronize the package index files from the their sources specified in /etc/apt/sources.list file. The update command fetched the packages from their locations and update the packages to newer version.
apt-get upgrade
# How to Upgrade Software Packages - The ‘upgrade‘ command is used to upgrade all the currently installed software packages on the system. Under any circumstances currently installed packages are not removed or packages which are not already installed neither retrieved and installed to satisfy upgrade dependencies.
apt-get dist-upgrade
# However, if you want to upgrade, unconcerned of whether software packages will be added or removed to fulfill dependencies, use the ‘dist-upgrade‘ sub command.
apt-get install netcat
# How Do I Install or Upgrade Specific Packages? - The ‘install‘ sub command is tracked by one or more packages wish for installation or upgrading.
apt-get install nethogs goaccess
# How I can Install Multiple Packages? - You can add more than one package name along with the command in order to install multiple packages at the same time. For example, the following command will install packages ‘nethogs‘ and ‘goaccess‘.
apt-get install '*name*'
# How to Install Several Packages using Wildcard - With the help of regular expression you can add several packages with one string. For example, we use * wildcard to install several packages that contains the ‘*name*‘ string, name would be ‘package-name’.
apt-get install packageName --no-upgrade
# How to install Packages without Upgrading - Using sub ‘–no-upgrade‘ command will prevent already installed packages from upgrading.
apt-get install packageName --only-upgrade
# How to Upgrade Only Specific Packages - The ‘–only-upgrade‘ command do not install new packages but it only upgrade the already installed packages and disables new installation of packages.
apt-get install vsftpd=2.3.5-3ubuntu1
# How Do I Install Specific Package Version? - Let’s say you wish to install only specific version of packages, simply use the ‘=‘ with the package-name and append desired version.
apt-get remove vsftpd
# How Do I Remove Packages Without Configuration - To un-install software packages without removing their configuration files (for later re-use the same configuration). Use the ‘remove‘ command as shown.
apt-get purge vsftpd
# How Do I Completely Remove Packages - To remove software packages including their configuration files, use the ‘purge‘ sub command as shown below.
apt-get remove --purge vsftpd
# Alternatively, you can combine both the commands together as shown below.
apt-get clean
# How I Can Clean Up Disk Space - The ‘clean‘ command is used to free up the disk space by cleaning retrieved (downloaded) .deb files (packages) from the local repository.
apt-get --download-only source vsftpd
# How Do I Download Only Source Code of Package - To download only source code of particular package, use the option ‘–download-only source‘ with ‘package-name’ as shown.
apt-get source vsftpd
# How Can I Download and Unpack a Package - To download and unpack source code of a package to a specific directory, type the following command.
apt-get --compile source goaccess
# How Can I Download, Unpack and Compile a Package - You can also download, unpack and compile the source code at the same time, using option ‘–compile‘ as shown below.
apt-get download nethogs
# How Do I Download a Package Without Installing - Using ‘download‘ option, you can download any given package without installing it. For example, the following command will only download ‘nethogs‘ package to current working directory.
apt-get changelog vsftpd
# How Do I Check Change Log of Package? - The ‘changelog‘ flag downloads a package change-log and shows the package version that is installed.
apt-get check
# How Do I Check Broken Dependencies? - The ‘check‘ command is a diagnostic tool. It used to update package cache and checks for broken dependencies.
apt-get build-dep netcat
# How Do I Search and Build Dependencies? - This ‘build-dep‘ command searches the local repositories in the system and install the build dependencies for package. If the package does not exists in the local repository it will return an error code.
apt-get autoclean
# How I Can Auto clean Apt-Get Cache? - The ‘autoclean‘ command deletes all .deb files from /var/cache/apt/archives to free-up significant volume of disk space.
apt-get autoremove vsftpd
# How I Can Auto remove Installed Packages? - The ‘autoremove‘ sub command is used to auto remove packages that were certainly installed to satisfy dependencies for other packages and but they were now no longer required. For example, the following command will remove an installed package with its dependencies.
apt-get upgrade | tee upgrade-$( date +%F ).log
# Do an apt upgrade and save a copy of the output to a current dated filename.
apt-get build-dep netcat
# How Do I Search and Build Dependencies? - This ‘build-dep‘ command searches the local repositories in the system and install the build dependencies for package. If the package does not exists in the local repository it will return an error code.
apt-get autoclean
# How I Can Auto clean Apt-Get Cache? - The ‘autoclean‘ command deletes all .deb files from /var/cache/apt/archives to free-up significant volume of disk space.
apt-get autoremove vsftpd
# How I Can Auto remove Installed Packages? - The ‘autoremove‘ sub command is used to auto remove packages that were certainly installed to satisfy dependencies for other packages and but they were now no longer required. For example, the following command will remove an installed package with its dependencies.
apt-get upgrade | tee upgrade-$( date +%F ).log
# Do an apt upgrade and save a copy of the output to a current dated filename.
apt-get install ifuse
ifuse /media/iPad
cp -v /media/iPad/DCIM/100APPLE/IMG*MOV /target
# mnt iPad filesystem.
apt-get upgrade | tee upgrade-$( date +%F ).log
# Do an apt upgrade and save a copy of the output to a current dated filename.
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command apt-get in a clear format. This allows users to quickly access the needed information for apt-get without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for apt-get are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
1.5 - 🖥️aptitude
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the aptitude command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# █████╗ ██████╗ ████████╗██╗████████╗██╗ ██╗██████╗ ███████╗
# ██╔══██╗██╔══██╗╚══██╔══╝██║╚══██╔══╝██║ ██║██╔══██╗██╔════╝
# ███████║██████╔╝ ██║ ██║ ██║ ██║ ██║██║ ██║█████╗
# ██╔══██║██╔═══╝ ██║ ██║ ██║ ██║ ██║██║ ██║██╔══╝
# ██║ ██║██║ ██║ ██║ ██║ ╚██████╔╝██████╔╝███████╗
# ╚═╝ ╚═╝╚═╝ ╚═╝ ╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚══════╝
# To search for packages:
aptitude search "whatever"
# To display package records for the named package(s):
aptitude show pkg(s)
# To install a package:
aptitude install package
# To remove a package:
aptitude remove package
# To remove unnecessary package:
aptitude autoclean
#==============================##==============================#
# CMD APTITUDE #
#==============================##==============================#
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command aptitude in a clear format. This allows users to quickly access the needed information for aptitude without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for aptitude are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
1.6 - 🖥️dpkg
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the dpkg command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██████╗ ██████╗ ██╗ ██╗ ██████╗
# ██╔══██╗██╔══██╗██║ ██╔╝██╔════╝
# ██║ ██║██████╔╝█████╔╝ ██║ ███╗
# ██║ ██║██╔═══╝ ██╔═██╗ ██║ ██║
# ██████╔╝██║ ██║ ██╗╚██████╔╝
# ╚═════╝ ╚═╝ ╚═╝ ╚═╝ ╚═════╝
# Install the package or upgrade it
dpkg -i test.deb
# Remove a package including configuration files
dpkg -P test.deb
# List all installed packages with versions and details
dpkg -I
# Find out if a Debian package is installed or not
dpkg -s test.deb | grep Status
#==============================#
# CMD dpkg Packetverwaltung
#==============================##==============================#
dpkg -l '*linux*' | grep '^ii'
# Get a list of debian packages with linux in their name and only list the ones that are fully installed.
dpkg -l '*3.19.0-2[56]*' | cat
# List packages with specific version and make sure the name column is visible by piping the output into cat.
dpkg -L packagename
# Matching files and packages in Debian/Ubuntu - To find out what files a package generated during installation.
dpkg -S /path/to/file
# We can also check the other way and find out what package a file belongs to
dpkg -S ls
# For the second command we need to use the full path as 'dpkg -S' just matches the string you supply it, so dpkg -S ls matches any package that has a file with 'ls' anywhere in the filename.
dpkg -S $( which notify-send )
# Find which Debian package the notify-send program is included with -> libnotify-bin
dpkg -l '*4.10.0*' | cat
# Sometimes in cases where columns are truncated, you can make them visible by passing output through cat.
# To organize the list in pages and columns ready for printing, issue the following command.
dpkg -l | pr --columns 3 -l 20
2017-01-06 13:19 Page 1
Desired=Unknown/Install ii adduser ii apg
| Status=Not/Inst/Conf- ii adwaita-icon-theme ii app-install-data
|/ Err?=(none)/Reinst-r ii adwaita-icon-theme- ii apparmor
||/ Name ii alsa-base ii apt
+++-=================== ii alsa-utils ii apt-clone
ii accountsservice ii anacron ii apt-transport-https
ii acl ii apache2 ii apt-utils
ii acpi-support ii apache2-bin ii apt-xapian-index
ii acpid ii apache2-data ii aptdaemon
ii add-apt-key ii apache2-utils ii aptdaemon-data
2017-01-06 13:19 Page 2
ii aptitude ii avahi-daemon ii bind9-host
ii aptitude-common ii avahi-utils ii binfmt-support
ii apturl ii aview ii binutils
ii apturl-common ii banshee ii bison
ii archdetect-deb ii baobab ii blt
ii aspell ii base-files ii blueberry
ii aspell-en ii base-passwd ii bluetooth
ii at-spi2-core ii bash ii bluez
ii attr ii bash-completion ii bluez-cups
ii avahi-autoipd ii bc ii bluez-obexd
.....
# Install profiling versions of all libghc dpkg packages
dpkg -l | grep libghc | grep "\-dev" | cut -d " " -f 3 | tr '\n' ' ' | sed -e 's/\-dev/\-prof/g' | xargs sudo apt-get install --yes
# Explanation:
# dpkg -l lists all installed system packages.
# grep libghc filters out all haskell packages
# grep "\-dev" filters out the actual source packages, where -dev can be replaced with -prof to get the name of the profiling package
# cut -d " " -f 3 converts lines from ii libghc-packagename-dev 0.1.3.3-7 amd64 description to libghc-packagename-dev
# tr '\n' ' ' Replaces newlines with spaces, merging it all into one line
# sed -e 's/\-dev/\-prof/g' Replaces -dev with -prof
# xargs sudo apt-get install --yes Passes the string (now looking like libghc-a-prof libghc-b-prof libghc-c-prof) as arguments to sudo apt-get install --yes which installs all package names it receives as arguments, and does not ask for confirmation.
# Limitations: Only works with apt (standard in ubuntu)
# List packages manually installed with process currently running - Sometimes we install programs, we forget about them, and they stay there wasting RAM. This one-liner try to find them.
ps -eo cmd | awk '{print $1}'| sort -u | grep "^/" | xargs dpkg -S 2>/dev/null | awk -F: '{print $1}' | sort -u | xargs apt-mark showmanual
# Sample output
# atom
# virtualbox
# bluez
# mosquitto
# teamviewer
# List the binaries installed by a Debian package - GNU grep's perl-compatible regular expression(PCRE).
function dpkgbinaries () { dpkg -L "$1" | grep -Po '.*/bin/\K.*'; }
# List the binaries installed by a Debian package - This shell function displays a list of binaries contained in an installed package; works on Debian based Linux distributions.
function dpgk-binaries () { for f in $(dpkg -L "$1" | grep "/bin/"); do basename "$f"; done; }
# Sample output
# $ binaries findutils
# find
# xargs
# List all ubuntu installed packages in a single line - Use xargs command to make one line.
dpkg --get-selections | grep -Evw 'deinstall$' | cut -f1 | sort -u | xargs
# List all ubuntu installed packages in a single line - This command lists all currently installed packages in ubuntu in a single line, for example to use later with apt install.
dpkg --get-selections | grep -v deinstall | sort -u | cut -f 1 | tr '\r\n' ' ' | sed '$s/ $/\n/'
# Sample output
# accountsservice acl acpid acpi-support adduser adwaita-icon-theme aisleriot alsa-base alsa-utils amd64-microcode anacron apg apparmor app-install-data-partner apport-gtk apport apport-symptoms appstream apt-clone apt-config-icons aptdaemon-data aptdaemon apt apturl-common apturl ... xserver-xorg-video-vesa xserver-xorg-video-vmware xul-ext-ubufox xwayland xxd xz-utils yaru-theme-gnome-shell yaru-theme-gtk yaru-theme-icon yaru-theme-sound yelp yelp-xsl zenity-common zenity zerofree zip zlib1g:amd64
#==============================##==============================#
# CMD dpkg #
#==============================##==============================#
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command dpkg in a clear format. This allows users to quickly access the needed information for dpkg without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for dpkg are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
1.7 - 🖥️dpkg-reconfigure
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the dpkg-reconfigure command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██████╗ ██████╗ ██╗ ██╗ ██████╗ ██████╗ ███████╗ ██████╗ ██████╗ ███╗ ██╗███████╗██╗ ██████╗ ██╗ ██╗██████╗ ███████╗
# ██╔══██╗██╔══██╗██║ ██╔╝██╔════╝ ██╔══██╗██╔════╝██╔════╝██╔═══██╗████╗ ██║██╔════╝██║██╔════╝ ██║ ██║██╔══██╗██╔════╝
# ██║ ██║██████╔╝█████╔╝ ██║ ███╗█████╗██████╔╝█████╗ ██║ ██║ ██║██╔██╗ ██║█████╗ ██║██║ ███╗██║ ██║██████╔╝█████╗
# ██║ ██║██╔═══╝ ██╔═██╗ ██║ ██║╚════╝██╔══██╗██╔══╝ ██║ ██║ ██║██║╚██╗██║██╔══╝ ██║██║ ██║██║ ██║██╔══██╗██╔══╝
# ██████╔╝██║ ██║ ██╗╚██████╔╝ ██║ ██║███████╗╚██████╗╚██████╔╝██║ ╚████║██║ ██║╚██████╔╝╚██████╔╝██║ ██║███████╗
# ╚═════╝ ╚═╝ ╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═══╝╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝
'dpkg-reconfigure tzdata'
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command dpkg-reconfigure in a clear format. This allows users to quickly access the needed information for dpkg-reconfigure without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for dpkg-reconfigure are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
2 - Packet Management Tools
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
Linux package management tools are essential for installing, updating, and removing software packages on a Linux system. These tools streamline the process of managing software, ensuring that all dependencies are resolved and that the system remains up-to-date. They provide a centralized way to handle software installations, making it easier to maintain a consistent and secure environment.
Package management tools are typically specific to different Linux distributions. For example, Arch-based systems use tools that follow a rolling release model, providing the latest software versions. Debian-based systems focus on stability and ease of use, offering a vast repository of precompiled packages. Red Hat-based systems are known for their robustness and enterprise-level support, using tools that handle .rpm packages.
Universal package management tools are designed to work across different Linux distributions. They provide a consistent way to install and manage software regardless of the underlying system. These tools aim to simplify software distribution and reduce compatibility issues, making it easier for developers to distribute their applications.
One of the key benefits of package management tools is their ability to automate software updates. This ensures that all installed software is kept up-to-date with the latest security patches and features. Additionally, package managers often include features for managing software repositories, allowing users to add or remove repositories as needed.
Overall, Linux package management tools are indispensable for maintaining a well-functioning and secure system. They simplify the process of managing software, ensuring that all dependencies are met and that the system remains up-to-date. Whether for personal use or in a professional setting, these tools play a vital role in effective system administration.
2.1 - 🖥️apk
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the apk command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# █████╗ ██████╗ ██╗ ██╗
# ██╔══██╗██╔══██╗██║ ██╔╝
# ███████║██████╔╝█████╔╝
# ██╔══██║██╔═══╝ ██╔═██╗
# ██║ ██║██║ ██║ ██╗
# ╚═╝ ╚═╝╚═╝ ╚═╝ ╚═╝
# apk is the tool used to install, upgrade, or delete software on a running system
# of Alpine Linux package management
# Install a package
apk add $package
# Remove a package
apk del $package
# Update repos
apk update
# Upgrade all packages
apk upgrade
# Find a package
apk search $package
# To list all installed packages, use:
apk info
# To determine which package a file belongs to:
apk info --who-owns /sbin/lbu
#==============================##==============================#
# CMD APK #
#==============================##==============================#
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command apk in a clear format. This allows users to quickly access the needed information for apk without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for apk are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
2.2 - 🖥️bower
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the bower command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
# ██╔══██╗██╔═══██╗██║ ██║██╔════╝██╔══██╗
# ██████╔╝██║ ██║██║ █╗ ██║█████╗ ██████╔╝
# ██╔══██╗██║ ██║██║███╗██║██╔══╝ ██╔══██╗
# ██████╔╝╚██████╔╝╚███╔███╔╝███████╗██║ ██║
# ╚═════╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
#==============================#
# CMD BOWER
#==============================##==============================#
# Install a package locally
bower install <package-name>
# Install a package locally directly from github
bower install <user>/<repo>
# Install a specific package locally
bower install <package-name>#<version>
# Install a package locally and save installed package into bower.json
bower install <package-name> --save
# Retrieve info of a particular package
bower info <package-name>
# List local packages
bower list
# Search for a package by name
bower search <package-name>
# Update a package to their newest version
bower update <package-name>
# Remove a local package
bower uninstall <package-name>
#==============================##==============================#
# CMD BOWER
#==============================##==============================#
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command bower in a clear format. This allows users to quickly access the needed information for bower without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for bower are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
2.3 - 🖥️cargo
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the cargo command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██████╗ █████╗ ██████╗ ██████╗ ██████╗
# ██╔════╝██╔══██╗██╔══██╗██╔════╝ ██╔═══██╗
# ██║ ███████║██████╔╝██║ ███╗██║ ██║
# ██║ ██╔══██║██╔══██╗██║ ██║██║ ██║
# ╚██████╗██║ ██║██║ ██║╚██████╔╝╚██████╔╝
# ╚═════╝╚═╝ ╚═╝╚═╝ ╚═╝ ╚═════╝ ╚═════╝
# Cargo is the Rust package manager
# Cargo downloads your Rust project's dependencies,
# compiles your project, makes packages, and upload them to crates.io
# To start a new project
cargo new hello_world --bin # program
cargo new hello_world --lib # library
# Build a project
cargo build
# Build a project with optimizations turned on
cargo build --release
# Updates dependencies in Cargo.lock
cargo update # update all
cargo update -p rand # updates just “rand”
# run the project tests (from src/ and tests/)
cargo test
# search for a package
cargo search
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command cargo in a clear format. This allows users to quickly access the needed information for cargo without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for cargo are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
2.4 - 🖥️carthage
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the carthage command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██████╗ █████╗ ██████╗ ████████╗██╗ ██╗ █████╗ ██████╗ ███████╗
# ██╔════╝██╔══██╗██╔══██╗╚══██╔══╝██║ ██║██╔══██╗██╔════╝ ██╔════╝
# ██║ ███████║██████╔╝ ██║ ███████║███████║██║ ███╗█████╗
# ██║ ██╔══██║██╔══██╗ ██║ ██╔══██║██╔══██║██║ ██║██╔══╝
# ╚██████╗██║ ██║██║ ██║ ██║ ██║ ██║██║ ██║╚██████╔╝███████╗
# ╚═════╝╚═╝ ╚═╝╚═╝ ╚═╝ ╚═╝ ╚═╝ ╚═╝╚═╝ ╚═╝ ╚═════╝ ╚══════╝
# carthage
# A dependency management tool for Cocoa applications (Mac OS X)
# Download the latest version of all dependencies mentioned in Cartfile, and build them:
carthage update
# Update dependencies, but only build for iOS:
carthage update --platform ios
# Update dependencies, but don't build any of them:
carthage update --no-build
# Download and rebuild the current version of dependencies (without updating them):
carthage bootstrap
# Rebuild a specific dependency:
carthage build dependency
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command carthage in a clear format. This allows users to quickly access the needed information for carthage without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for carthage are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
3 - Red Hat based
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
Red Hat-based package management systems use tools to manage software packages in .rpm format. They are known for their robustness and enterprise-level support. Package management includes handling dependencies, managing software repositories, and maintaining system security and performance. Red Hat-based systems are widely used in enterprise environments for their stability and support.
3.1 - 🖥️dnf
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the dnf command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██████╗ ███╗ ██╗███████╗
# ██╔══██╗████╗ ██║██╔════╝
# ██║ ██║██╔██╗ ██║█████╗
# ██║ ██║██║╚██╗██║██╔══╝
# ██████╔╝██║ ╚████║██║
# ╚═════╝ ╚═╝ ╚═══╝╚═╝
# To install the latest version of a package:
dnf install <package name>
# To search package details for the given string
dnf search <string>
# To find which package provides a binary
dnf provides <path to binary>
# The following are available after installing "dnf-plugins-core"
# Download a package
dnf download <package name>
# install the build dependencies for a SRPM or from a .spec file
dnf builddep <srpm/.spec file>
#==============================##==============================#
# CMD dnf #
#==============================##==============================#
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command dnf in a clear format. This allows users to quickly access the needed information for dnf without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for dnf are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
3.2 - 🖥️rpm
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the rpm command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██████╗ ██████╗ ███╗ ███╗
# ██╔══██╗██╔══██╗████╗ ████║
# ██████╔╝██████╔╝██╔████╔██║
# ██╔══██╗██╔═══╝ ██║╚██╔╝██║
# ██║ ██║██║ ██║ ╚═╝ ██║
# ╚═╝ ╚═╝╚═╝ ╚═╝ ╚═╝
# To install a package:
rpm -ivh <rpm>
# To remove a package:
rpm -e <package>
# To remove a package, but not its dependencies
rpm -e --nodeps <package>
# To find what package installs a file:
rpm -qf </path/to/file>
# To find what files are installed by a package:
rpm -ql <package>
rpm -qpl <rpm>
# To find what packages require a package or file:
rpm -q --whatrequires <package>
rpm -q --whatrequires <file>
# To list all installed packages:
rpm -qa
# To find a pkg's dependencies
rpm -i --test <package>
# Display checksum against source
rpm -K <package>
# Verify a package
rpm -V <package>
#==============================#
# CMD rpm Packetverwaltung
#==============================##==============================#
rpm -qa --filesbypkg | grep " /var/log/"
# List all rpm packaged files in /var/log by what rpm they belong to.
rpm -qa | grep -e http -e php -e mariadb | xargs rpm -V
# Quickly check the integrity of the "AMP" stack on rpm based systems.
rpm -qa --queryformat "%{NAME} %{INSTALLTIME:date}\n" | grep "Nov 2015"
# In RPM, determine which packages where installed in Nov 2015.
rpm -qf $( which lspci )
# Pass the output of which (showing path to lspci) into rpm -qf, which tells you the pkg.
rpm -qa --last | head
# Show the last 10 packages installed on an RPM based host.
rpm -qa --last | tail
# Show the last 10 packages installed on an RPM based host.
rpm -qa | grep -e http -e php -e mariadb | xargs rpm -V
# Quickly check the integrity of the "AMP" stack on rpm based systems.
rpm --dbpath=/oldserverbackup/var/lib/rpm -q perl-Date-Manip
# Specify an alternate rpm database path using --dbpath.
rpm -q -p -filesbypkg Myfile.rpm
# List content of rpm file
rpmdir="$(grep "^%_topdir" /usr/lib/rpm/macros | sed -e s#"^.*%{getenv:HOME}"#"${HOME}"#g -e s#"^.*%{_usrsrc}"#"/usr/src"#g)";
# Get the correct RPM Build directory
rpm -qa --queryformat "%-47{NAME} %{PACKAGER}\n"
# Generate list of installed RPM names(left align) and their packager in formated columns.
# Check when package was installed/updated -> Though technically it’s not one of the yum tips but rather a RPM one but none the less, it’s pretty useful & comes handy at times. We can check when a package has been installed or when its was last update by running the following command,
rpm -qa –last
# To know when a particular package has been installed, execute the following command,
rpm -q package_name –last
rpm -qa --last | head
# Show the last 10 packages installed on an RPM based host.
# Print the 16 most recent RPM packages installed in newest to oldest order
rpm -qa --last | head -n 16
rpm -qa --queryformat "%10{SIZE} %{NAME}\n" | grep -Ev "(kernel|glibc|perl$|python-libs$|coreutils|hwdata$|glib2|grub2$|yum$|binutils$)" | sort -rn | head -100
# Show the largest #rpm packages on the system, omitting *some* of the critical ones
#Print the 16 most recent RPM packages installed in newest to oldest order
rpm -qa --last | head -n 16
rpm -qa --queryformat '%{INSTALLTIME} %{name}-%{version}-%{release}\n' | sort -k 1,1 -rn | nl | head -16 | awk '{printf("%3d %s %s\n", $1,strftime("%c",$2),$3)}'
rpm -qa --queryformat '%{INSTALLTIME} %{name}-%{version}-%{release}\n' | sort -k 1,1 -rn | nl | head -16 | awk '{printf("%3d %s %s\n", $1,strftime("%c",$2),$3)}'
# Print the 16 most recent RPM packages installed in newest to oldest order
# Display a list of the 16 most recently installed RPM packages with newest first.
1 Wed 12 Sep 2018 15:41:27 BST google-chrome-stable-69.0.3497.92-1
2 Fri 07 Sep 2018 19:00:03 BST qrencode-3.4.4-3.mga5
3 Fri 07 Sep 2018 19:00:03 BST lib64qrencode3-3.4.4-3.mga5
4 Mon 03 Sep 2018 15:40:12 BST lib64mariadb18-10.0.36-1.mga5
5 Tue 24 Jul 2018 09:31:50 BST thunderbird-en_GB-52.9.1-1.mga5
6 Tue 24 Jul 2018 09:31:50 BST rootcerts-java-20180411.00-1.mga5
7 Tue 24 Jul 2018 09:31:50 BST rootcerts-20180411.00-1.mga5
8 Tue 24 Jul 2018 09:31:49 BST thunderbird-52.9.1-1.mga5
9 Tue 24 Jul 2018 09:31:46 BST nss-3.28.6-1.4.mga5
10 Tue 24 Jul 2018 09:31:46 BST lib64nss3-3.28.6-1.4.mga5
11 Tue 24 Jul 2018 09:31:46 BST lib64nspr4-4.19-1.mga5
12 Sat 21 Jul 2018 18:43:41 BST xclip-0.12-7.mga5
13 Fri 13 Jul 2018 10:39:35 BST lib64pathplan4-2.38.0-10.1.mga5
14 Fri 13 Jul 2018 10:39:35 BST lib64gvc6-2.38.0-10.1.mga5
15 Fri 13 Jul 2018 10:39:35 BST lib64cgraph6-2.38.0-10.1.mga5
16 Fri 13 Jul 2018 10:39:35 BST lib64cdt5-2.38.0-10.1.mga5
rpm -qa | sed 's/^\(.*\)-\([^-]\{1,\}\)-\([^-]\{1,\}\)$/\1 \2 \3/' | sort | column -t
# Extract rpm package name, version and release using some fancy sed regex
# This command could seem pretty pointless especially when you can get the same result more easily using the rpm builtin queryformat, like: rpm -qa --qf "%{NAME} %{VERSION} %{RELEASE}.%{ARCH}\n" | sort | column -t but nonetheless I've learned that sometimes it can be quite interesting trying to explore alternative ways to accomplish the same task (as Perl folks like to say: There's more than one way to do it!) Show Sample Output:
# [root@docker ~]# rpm -qa | sed 's/^\(.*\)-\([^-]\{1,\}\)-\([^-]\{1,\}\)$/\1 \2 \3/' | sort | column -t
# acl 2.2.51 14.el7.x86_64
# aic94xx-firmware 30 6.el7.noarch
# alsa-firmware 1.0.28 2.el7.noarch
# alsa-lib 1.1.6 2.el7.x86_64
# alsa-tools-firmware 1.1.0 1.el7.x86_64
# atop 2.3.0 8.el7.x86_64
# audit 2.8.4 4.el7.x86_64
# audit-libs 2.8.4 4.el7.x86_64
# audit-libs-python 2.8.4 4.el7.x86_64
# authconfig 6.2.8 30.el7.x86_64
# basesystem 10.0 7.el7.centos.noarch
# bash 4.2.46 31.el7.x86_64
# bash-completion 2.1 6.el7.noarch
# bc 1.06.95 13.el7.x86_64
# bind-libs 9.9.4 73.el7_6.x86_64
# bind-libs-lite 9.9.4 73.el7_6.x86_64
# bind-license 9.9.4 73.el7_6.noarch
# bind-utils 9.9.4 73.el7_6.x86_64
# binutils 2.27 34.base.el7.x86_64
# [... snip ...]
rpm -ql coreutils | egrep '\.gz' | xargs -L1 zfgrep -A1 'SH NAME' | sort -u
# Find primes w/ PCRE. - PrimeDay
rpm -qa --last | head
# Show the last 10 packages installed on an RPM based host.
#==============================##==============================#
# CMD RPM #
#==============================##==============================#
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command rpm in a clear format. This allows users to quickly access the needed information for rpm without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for rpm are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
3.3 - 🖥️rpm2cpio
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the rpm2cpio command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██████╗ ██████╗ ███╗ ███╗██████╗ ██████╗██████╗ ██╗ ██████╗
# ██╔══██╗██╔══██╗████╗ ████║╚════██╗██╔════╝██╔══██╗██║██╔═══██╗
# ██████╔╝██████╔╝██╔████╔██║ █████╔╝██║ ██████╔╝██║██║ ██║
# ██╔══██╗██╔═══╝ ██║╚██╔╝██║██╔═══╝ ██║ ██╔═══╝ ██║██║ ██║
# ██║ ██║██║ ██║ ╚═╝ ██║███████╗╚██████╗██║ ██║╚██████╔╝
# ╚═╝ ╚═╝╚═╝ ╚═╝ ╚═╝╚══════╝ ╚═════╝╚═╝ ╚═╝ ╚═════╝
# List contents of RPM
rpm2cpio foo.rpm | cpio -vt
# Extract contents of RPM
rpm2cpio foo.rpm | cpio -vid
#==============================##==============================#
# CMD RPM2CPIO #
#==============================##==============================#
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command rpm2cpio in a clear format. This allows users to quickly access the needed information for rpm2cpio without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for rpm2cpio are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
3.4 - 🖥️yum
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the yum command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██╗ ██╗██╗ ██╗███╗ ███╗
# ╚██╗ ██╔╝██║ ██║████╗ ████║
# ╚████╔╝ ██║ ██║██╔████╔██║
# ╚██╔╝ ██║ ██║██║╚██╔╝██║
# ██║ ╚██████╔╝██║ ╚═╝ ██║
# ╚═╝ ╚═════╝ ╚═╝ ╚═╝
# To install the latest version of a package:
yum install <package name>
# To perform a local install:
yum localinstall <package name>
# To remove a package:
yum remove <package name>
# To search for a package:
yum search <package name>
# To find what package installs a program:
yum whatprovides </path/to/program>
# To find the dependencies of a package:
yum deplist <package name>
# To find information about a package:
yum info <package name>
# List currently enabled repositories:
yum repolist
# List packages containing a certain keyword:
yum list <package_name_or_word_to_search>
# To download the source RPM for a package:
yumdownloader --source <package name>
# (You have to install yumdownloader first, which is installed by the yum-utils package)
#==============================#
# CMD YUM
#==============================##==============================#
yum install package-with-long-name{,-devel}
# Brace expansion quickly appends the devel pacakge as well to your list.
yum install package-with-long-name{,-devel}
# Brace expansion quickly appends the devel pacakge as well to your list.
yum search python | grep ^python
#Search for available python packages through yum, but only show lines for packages starting with python.
yum search php | grep ^php
# Search for available PHP packages through yum, but only show lines for packages starting with php.
# Some pretty useful YUM tips & tricks
#########################################
# Downgrade a package -> You might have come across this issue or might run into someday, where you have upgraded a package that was not meant to be upgraded or you have upgraded a package with good intentions but its causing you some trouble. With YUM , we have option to downgrade a package to the previous version, just open your terminal & execute the following command,
yum downgrade package_name
# Yum shell -> This yum tip is actually known to pretty few. We can actually start a Yum Shell & use it to manage packages. To start the yum shell, open terminal & type Now shell for yum will be started & we can run all the shell command minus the yum at the beginning. For example ‘search package_name’
yum shell
# Install only security updates -> To actually do this, we need to install a plugin called ‘yum-plugin-security’. We don’t need to install this plugin on RHEL 7, as it’s already part of yum. To install the plugin on RHEL 6 , execute the following command,
yum install yum-plugin-security
# Once plugin has bee installed, we can check the list of errates by executing the following command,
yum updateinfo list available
# To check all available security updates, run
yum updateinfo list security all
yum updateinfo list sec
# To install only the errata updates, run
yum update-minimal –security -y
# To download & apply all the security updates, run
yum update –security -y
# Extensive "cleanup" operations following "sudo yum upgrade"
yum upgrade && for pkg in $(package-cleanup --orphans -q); do repoquery $(rpm -q $pkg --queryformat="%{NAME}") | grep -q ".*" && echo $pkg; done | xargs sudo yum -y remove && for pkg in $(package-cleanup --leaves --all -q); do repoquery --groupmember $pkg | grep -q "@" || echo $pkg; done
# Explanation: "sudo yum upgrade" does clean up outdated packages that the current upgrade replaces, but not other outdated packages or the ones that it willfully skips. Yes, that's what "package-cleanup --orphans" will finish, but "orphaned packages" also include packages that are at their latest version but just aren't updated by the repositories (usually a discrete .rpm installation). This one-liner uses "package-cleanup --orphans" but wraps around it to skip packages that aren't in the repositories anyway and just removes outdated packages that have a newer version in the repositories. No, it's not at the end yet. It has a final command to display all packages that do not belong to any group. Choose any of the "manual extension" packages which aren't really necessary and only clog the system.
# Limitations:
# Specific to only rpm and yum
# No, not just yum, it requires the yum-utils package (or whatever else provides package-cleanup and repoquery, if anything)
#==============================##==============================#
# CMD YUM
#==============================##==============================#
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command yum in a clear format. This allows users to quickly access the needed information for yum without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for yum are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
4 - Universal
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
Universal package management systems are designed to work across different Linux distributions. They provide a consistent way to install and manage software regardless of the underlying system. Universal package managers aim to simplify software distribution and reduce compatibility issues. They offer a centralized platform for software updates and installations.
4.1 - 🖥️snap
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the snap command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ███████╗███╗ ██╗ █████╗ ██████╗
# ██╔════╝████╗ ██║██╔══██╗██╔══██╗
# ███████╗██╔██╗ ██║███████║██████╔╝
# ╚════██║██║╚██╗██║██╔══██║██╔═══╝
# ███████║██║ ╚████║██║ ██║██║
# ╚══════╝╚═╝ ╚═══╝╚═╝ ╚═╝╚═╝
# To find the `foo` snap:
snap find foo
# To view detailed information about snap `foo`:
snap info foo
# To view all private snaps (must be logged in):
snap find --private
# To install the `foo` snap:
sudo snap install foo
# To install the `foo` snap from the "beta" channel:
sudo snap install foo --channel=beta
# To view installed snaps:
snap list
# To list all revisions of installed snaps:
snap list --all
# To (manually) update all snaps:
sudo snap refresh
# To (manually) update the `foo` snap:
sudo snap refresh foo
# To update the `foo` snap to the "beta" channel:
sudo snap refresh foo --channel=beta
# To revert the `foo` snap to a prior version:
sudo snap revert foo
# To revert the `foo` snap to revision 5:
snap revert foo --revision 5
# To remove the `foo` snap:
sudo snap remove foo
# To log in to snap (must first create account online):
sudo snap login
# To log out of snap:
snap logout
# To view a transaction log summary:
snap changes
# To view details of item 123 in the transaction log:
snap change 123
# To watch transaction 123:
snap watch 123
# To abort transaction 123:
snap abort 123
# To download the `foo` snap (and its assertions) *without* installing it:
snap download foo
# To install the locally-downloaded `foo` snap with assertions:
snap ack foo.assert
snap install foo.snap
# To install the locally-downloaded `foo` snap without assertions:
# NB: this is dangerous, because the integrity of the snap will not be
# verified. You should only do this to test a snap that you are currently
# developing.
snap install --dangerous foo.snap
# To install snap `foo` in "dev mode":
# NB: this is dangerous, and bypasses the snap sandboxing mechanisms
snap install --devmode foo
# To install snap `foo` in "classic mode":
# NB: this is likewise dangerous
snap install --classic foo
# To view available snap interfaces:
snap interfaces
# To connect the `foo:camera` plug to the ubuntu core slot:
snap connect foo:camera :camera
# To disconnect the `foo:camera` plug from the ubuntu core slot:
snap disconnect foo:camera
# To disable the `foo` snap
snap disable foo
# To enable the `foo` snap
snap enable foo
# To set snap `foo`'s `bar` property to 10:
snap set foo bar=10
# To read snap `foo`'s current `bar` property:
snap get foo bar
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command snap in a clear format. This allows users to quickly access the needed information for snap without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for snap are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
5 - ➡️ Arch based
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
Package management for Arch-based systems involves tools and processes for installing, updating, and removing software packages. These systems typically use a rolling release model, providing the latest software versions. Package management ensures that software dependencies are resolved and that the system remains up-to-date. It also allows users to customize their installations with minimal bloat.
5.1 - 🖥️pacman
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the pacman command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██████╗ █████╗ ██████╗███╗ ███╗ █████╗ ███╗ ██╗
# ██╔══██╗██╔══██╗██╔════╝████╗ ████║██╔══██╗████╗ ██║
# ██████╔╝███████║██║ ██╔████╔██║███████║██╔██╗ ██║
# ██╔═══╝ ██╔══██║██║ ██║╚██╔╝██║██╔══██║██║╚██╗██║
# ██║ ██║ ██║╚██████╗██║ ╚═╝ ██║██║ ██║██║ ╚████║
# ╚═╝ ╚═╝ ╚═╝ ╚═════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝ ╚═══╝
# All the following command work as well with multiple package names
# To search for a package
pacman -Ss <package name>
# To update the local package base and upgrade all out of date packages
pacman -Suy
# To install a package
pacman -S <package name>
# To uninstall a package
pacman -R <package name>
# To uninstall a package and his depedencies, removing all new orphans
pacman -Rcs <package name>
# To get informations about a package
pacman -Si <package name>
# To install a package from builded package file (.tar.xz)
pacman -U <file name/file url>
# To list the commands provided by an installed package
pacman -Ql <package name> | sed -n -e 's/.*\/bin\///p' | tail -n +2
# To list explicitly installed packages
pacman -Qe
# To list orphan packages (installed as dependencies and not required anymore)
pacman -Qdt
# You can't directly install packages from the Arch User Database (AUR) with pacman.
# You need yaourt to perform that. But considering yaourt itself is in the AUR, here is how to build a package from its tarball.
# Installing a package from AUR is a relatively simple process:
# - Retrieve the archive corresponding to your package from AUR website
# - Extract the archive (preferably in a folder for this purpose)
# - Run makepkg in the extracted directory. (makepkg-s allows you to install any dependencies automatically from deposits.)
# - Install the package created using pacman
# Assuming $pkgname contains the package name.
wget "https://aur.archlinux.org/packages/${pkgname::2}/$pkgname/$pkgname.tar.gz"
tar zxvf "$pkgname.tar.gz"
cd "$pkgname"
# Build the package
makepkg -s
# Install
sudo pacman -U <package file (.pkg.tar.xz)>
# Arch Linux sort installed packages by size - This version accounts for the MiB/KiB suffix output by pacman these days.
pacman -Qi | grep 'Name\|Size\|Description' | cut -d: -f2 | paste - - - | awk -F'\t' 'BEGIN{ s["MiB"]=1024; s["KiB"]=1;} {split($3, a, " "); print a[1] * s[a[2]], "KiB", $1}' | sort -n
pacman -Fs libusb-0.1.so.4
# Arch Linux: Search for missing libraries using pacman If, while using a program, you get an error similar to: error while loading shared libraries: libusb-0.1.so.4: cannot open shared object file: No such file or directory Use pacman or pkgfile to search for the package that owns the missing library https://wiki.archlinux.org/index.php/General_troubleshooting#Message:_%22error_while_loading_shared_libraries%22 Show Sample Output:
# extra/libusb-compat 0.1.5-1
# usr/lib/libusb-0.1.so.4
#==============================##==============================#
# CMD PACMAN #
#==============================##==============================#
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command pacman in a clear format. This allows users to quickly access the needed information for pacman without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for pacman are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
5.2 - 🖥️yaourt
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the yaourt command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██╗ ██╗ █████╗ ██████╗ ██╗ ██╗██████╗ ████████╗
# ╚██╗ ██╔╝██╔══██╗██╔═══██╗██║ ██║██╔══██╗╚══██╔══╝
# ╚████╔╝ ███████║██║ ██║██║ ██║██████╔╝ ██║
# ╚██╔╝ ██╔══██║██║ ██║██║ ██║██╔══██╗ ██║
# ██║ ██║ ██║╚██████╔╝╚██████╔╝██║ ██║ ██║
# ╚═╝ ╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝ ╚═╝
# All pacman commands are working the same way with yaourt.
# Just check the pacman cheatsheet.
# For instance, to install a package :
pacman -S <package name>
yaourt -S <package name>
# The difference is that yaourt will also query the Arch User Repository,
# and if appropriate, donwload the source and build the package requested.
# Here are the commands yaourt provides while pacman doesn't :
# To search for a package and install it
yaourt <package name>
# To update the local package base and upgrade all out of date package, including the ones from
AUR and the packages based on development repos (git, svn, hg...)
yaourt -Suya --devel
# For all of the above commands, if you want yaourt to stop asking constantly for confirmations,
use the option --noconfirm
# To build a package from source
yaourt -Sb <package name>
#==============================##==============================#
# CMD YAOURT #
#==============================##==============================#
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command yaourt in a clear format. This allows users to quickly access the needed information for yaourt without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for yaourt are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
5.3 - 🖥️yay
➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the yay command with important options and switches using examples.
▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁
# ██╗ ██╗ █████╗ ██╗ ██╗
# ╚██╗ ██╔╝██╔══██╗╚██╗ ██╔╝
# ╚████╔╝ ███████║ ╚████╔╝
# ╚██╔╝ ██╔══██║ ╚██╔╝
# ██║ ██║ ██║ ██║
# ╚═╝ ╚═╝ ╚═╝ ╚═╝
# present package selection menu
yay [Search Term]
# print system statistics
yay -Ps
# print update list
yay -Pu
# clean unneeded dependencies
yay -Yc
# downloads PKGBUILD from ABS or AUR
yay -G
# generates development package
# DB used for devel updates.
yay -Y --gendb
# normal update but also check for development package updates
# and use PKGBUILD modification time and not version to determine update
yay -Syu --devel --timeupdate
# instalation
git clone https://aur.archlinux.org/yay.git
cd yay
makepkg -si
Cheatsheets are an excellent complement to other information sources like Linux man-pages, Linux help, or How-To’s and tutorials, as they provide compact and easily accessible information. While man-pages and detailed tutorials often contain comprehensive explanations and extensive guides, cheatsheets summarize the most important options forthe command yay in a clear format. This allows users to quickly access the needed information for yay without having to sift through lengthy texts. Especially in stressful situations or for recurring tasks, cheatsheets for yay are a valuable resource to work efficiently and purposefully.
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
█║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌
██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗███████╗██████╗
████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
╚██╔═██╔╝██║ ██║██║ ██║ ╚███╔╝ █████╗ ██║ ██║
████████╗██║ ██║██║ ██║ ██╔██╗ ██╔══╝ ██║ ██║
╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═════╝
█║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░