Useful commands

Command NameDescription
envPrint all environment variables for the current user
filePrint out the type of the file
perf
perf top
perf record
Show and record lots of Linux performance data (not on MacOS or OpenBSD) JE Zine
lessPager for text files JE comic
Try & while in the pager to filter lines, ! to anti-filter lines
expand/unexpandConvert from tabs to spaces (expand) or spaces to tabs (unexpand -a).
dmidecodePrint out BIOS information (including most of the devices connected)
hwinfoPrint out hardware info
lshwList hardware
inxiShow a compressed view of the system hardware (often used for IRC sharing)
fwupdmgrFirmware update manager (to run BIOS updates)
nvtopMonitor for GPU consumption
rlwrapAdd history/Ctrl support for repls that don't have them (i.e. Python)
watchRe-run a command every 2 seconds
calA little CLI calendar
pvGive you stats on data going through a pipe
tsPut a timestamp in front of every line
ncduFigure out what's using your disk space.
diffFind out the difference between 2 files. Add -U 8 for context.
commFind out the lines that 2 already-sorted files have in common
columnFormat the output into columns
xsel/xclip
MacOS: pbcopy/pbpaste
Copy + paste into system clipboard.
dnspeepInspect DNS requests (repo)
gitDistributed version control (JE subcommands
mitmproxyMan-in-the-middle network proxy, for sniffing traffic. JE comic
ss -tunaplShow open sockets (JE comic)
ngrepListen to network traffic (simplified tcpdump, JE comic

Mouse

IssueHow to fix
Mouse locks upFrom root command line:
1. modprobe -r psmouse
2. modprobe psmouse
Many thanks to Julia Evans, Nixcraft, and others for the inspiration.