Whether you're a backend dev, frontend dev, or DevOps enthusiast — knowing your way around Linux will supercharge your workflow.

In this blog, I’ve curated 20+ essential Linux commands every developer should know, plus a quick Ubuntu cleanup cheat sheet to keep your system fast and smooth. Let's dive in! 👇

Here’s a list of 20+ Linux commands that can make your life easier as a developer.

● pwd — Print Working Directory (Shows the full path of your current directory).

pwd

● ls — List Directory Contents (Lists all files and folders in the current directory).

ls
ls -l     # Detailed list
ls -a     # Include hidden files

● cd — Change Directory (Move between folders).

cd /path/to/folder
cd ~       # Go to home directory
cd ..      # Go one level up

● touch — Create a File (Quickly create an empty file).

touch myfile.txt

● mkdir — Make Directory (Create a new folder).

mkdir myfolder

● rm — Remove Files or Folders (Deletes files or directories carefully).

rm myfile.txt
rm -r myfolder   # Delete folder recursively

● cp — Copy Files and Folders (Copies files or entire directories).

cp source.txt destination.txt
cp -r src_folder/ dest_folder/

● mv — Move or Rename Files (Move or rename files and directories).

mv oldname.txt newname.txt
mv file.txt /path/to/new/folder/

● cat — View File Contents (Prints the contents of a file to the terminal).

cat myfile.txt

● nano or vim — Edit Files from Terminal (Simple terminal-based text editors).

nano myfile.txt
vim myfile.txt

● nano or vim — Edit Files from Terminal (Simple terminal-based text editors).

nano myfile.txt
vim myfile.txt

● grep — Search Text Inside Files (Find specific words or patterns inside files).

grep "keyword" filename.txt
grep -r "functionName" src/

● find — Find Files and Directories (Search for files across the system).

find /path/to/search -name "filename.txt"

● chmod — Change File Permissions (Manage who can read, write, or execute files).

chmod +x script.sh   # Make script executable

● ps — Check Running Processes (See what processes are running).

ps aux

● kill — Kill a Process (Force-stop a running process using its PID (Process ID)).

kill PID
kill -9 PID    # Force kill

● top or htop — Monitor System Usage (Real-time view of CPU, memory usage, and processes).

htop    # (if installed, more visual)

● tar — Archive and Extract Files (Compress and extract .tar.gz or .tar files).

tar -czvf archive.tar.gz folder/
tar -xzvf archive.tar.gz

● curl — Transfer Data from URLs (Make API requests or download files).

curl https://api.example.com/data

● wget — Download Files (Download a file directly from the internet).

wget https://example.com/file.zip

● history — See Command History (See the list of commands you've run previously).

history

🎁 Bonus: Ubuntu Clean and Update Commands Cheat Sheet

Keep your Ubuntu machine clean and updated with these quick commands:

🌌 Clean Temporary Files

sudo apt autoremove
sudo apt clean

📈 Update System

sudo apt update && sudo apt upgrade

Final Thoughts
These Linux commands are like superpowers for developers.
Mastering them saves you time, makes you faster, and brings you closer to truly understanding how your system works under the hood.

If you're new to Linux, pick 3–5 commands first, use them daily, and slowly grow your command-line fluency.

💬 Over to You!
What’s your favorite Linux command?
Drop it in the comments below — let’s build the ultimate developer terminal toolkit together! 💪