moves the cursor to the beginning of the command line
end
moves the cursor to the end of the command line
Ctrl-W
deletes the word immediately before the cursor
Ctrl-K
deletes everything immediately after the cursor
Ctrl-Y
undo a deletion
Ctrl-C
cancels the active process
Up
cycles through previously made commands
Tab
auto completes if there's only one possibility
Shift-pg up/home
move up the terminal (handy with no scroll bar)/go to top
Shift-pg dn/end
move down the termnal/go back to the prompt (down does too)
Ctrl-R
shows reverse history, type a few letters to search a previous line, then press Ctrl-R repeatedly to find the command, and press Right, to edit, or hit Enter to execute
Apt commands
apt check [package]
check dependencies
apt install -s [package]
simulate install
sudo apt build-dep [package]
attempt to install dependencies
apt install [package]
install package
apt install -f [package]
install without broken dependencies
apt install --reinstall [package]
reinstall package
apt remove [package]
remove package
apt remove --purge [package]
remove package including its config files
apt clean
clean cache
apt autoclean
clean cache from packages that can't be downloaded
apt install -f
clean broken install
sudo dpkg --configure -a
or, failing that
apt-cache search [package]
search for packages in the apt cache with a name, or part of a name
paramaters:
install - Lists all packages that have been installed.
upgrade - Lists all packages that have been upgraded.
remove - Lists all packages that have been removed.
rollback - Lists rollback information.
list - Lists all contents of dpkg logs.