3 Linux Commands That Feel Like Cheating

By Sherif Atitebi | June 13, 2026


I am relatively new to the Linux environment and world. But so far, I like the experience of using Linux as an operating system. It isn't my main OS, Microsoft still has me on a chokehold. But I will incorporate it more into my developer tool belt.

The version of Linux I am using is Raspberry Pi OS. I know, it isn't a full-fledged kernel on a laptop. This is what I have now and I think it will be very useful to get me familiar and a needed learning curve.

So I've been poking around the terminal, breaking things, fixing them, googling errors at 1am. The usual. And in the process I've stumbled on a few commands that genuinely made me stop and go "wait, why didn't anyone tell me about this earlier?" Not the basic stuff like ls and cd, those get covered in every beginner tutorial. I mean the commands that actually save you time once you start using the terminal as more than just a place to install things.

There are three in particular that I keep reaching for. And the reason I'm writing about them is because if you're like me, somewhat new, mostly self-taught, figuring it out as you go, these will probably hit the same way they hit me.

━━━━━━━━━━━━━━━

1. history | grep

━━━━━━━━━━━━━━━

The first time I needed to re-run a command I'd typed two days earlier, I did what most beginners do. I pressed the up arrow about forty times. I scrolled. I gave up and just retyped it from memory, badly.

Then I learned about history. On its own, it just dumps every command you've ever typed into the terminal. Which is helpful but also overwhelming, because you might have hundreds of lines.

The real trick is piping it into grep:

▸ history | grep apt

That gives you every line in your history that contains the word "apt". You can grep for anything ssh, python, a filename you half-remember. It's like Ctrl+F for your terminal past.

The bonus tricks that pair with this:

▸ !! (re-run the last command you typed)

▸ sudo !! (re-run the last command but with sudo, absolute lifesaver)

▸ !$ (reuse the last argument from your previous command)

━━━━━━━━━━━━━━━

2. watch

━━━━━━━━━━━━━━━

This one feels like a cheat code. Sometimes you want to monitor something that changes over time — disk usage, memory, a folder filling up with files. The beginner instinct is to keep running the same command every few seconds like a maniac.

watch does it for you:

▸ watch df -h

That runs df -h every two seconds and refreshes the screen with the new output. You can change the interval with -n:

▸ watch -n 1 free -h

Now you have a live dashboard for your RAM. On a Raspberry Pi this is especially useful because the Pi is a small machine and you actually do care about what it's doing with its limited resources. I use it to watch downloads, monitor temperature, check folder sizes, anything where the answer changes and I want to see it change.

Press Ctrl+C to exit. That part is satisfying every single time.

━━━━━━━━━━━━━━━

3. tmux

━━━━━━━━━━━━━━━

This is the one that genuinely changed how I use the terminal.

tmux is a terminal multiplexer, which is a fancy way of saying it lets you split your terminal into multiple panes and keep your sessions alive even when you close the window. On the Pi, it doesn't come pre-installed, so the first step is:

▸ sudo apt install tmux -y

Then you start a session:

▸ tmux new -s demo

Once you're inside tmux, the commands all start with Ctrl+B, then a second key:

▸ Ctrl+B then % → split the pane vertically

▸ Ctrl+B then ↑↓←→ → move between panes

▸ Ctrl+B then d → detach from the session

That last one is the magic. When you detach, the session keeps running in the background. You can close the terminal, walk away, come back later, and reattach:

▸ tmux ls (see your running sessions)

▸ tmux attach -t demo

This is huge for the Pi specifically. I can SSH in, start a long-running script inside tmux, detach, close my laptop, and the script just keeps going. No screen sessions dying, no lost work. It feels like a power-up.

━━━━━━━━━━━━━━━

Wrapping up

━━━━━━━━━━━━━━━

None of these commands are secrets. They're all in the man pages and they all show up if you go looking. But "if you go looking" is doing a lot of work in that sentence, because as a beginner you don't know what you're supposed to be looking for.

So consider this me telling you what to look for. Pick one, use it for a week, and let it become muscle memory. Then come back for the next one.

I'm still figuring this whole Linux thing out. But it's commands like these that make the figuring-out feel less like punishment and more like unlocking something.

ABOUT ME

My name is Sherif. This blog is made on the top of my Favourite full stack Framework 'Django', follow up the tutorial to learn how I made it..!