Command of the day One command a day, the same for everyone. The card changes at 00:00 UTC.
No. 1
Date 10 Nov 2026
Learning goal Terminal Start, lesson 2
Level 1 of 3 Command of the day No. 1: pwd Purpose: Shows the folder you are in right now.
Syntax: pwd
Example:
$ pwd
/home/lerner Output from the simulator, as on a real Linux.
Options:
-P shows the real path, with symbolic links resolved Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 2
Date 10 Nov 2026
Learning goal Terminal Start, lesson 2
Level 1 of 3 Command of the day No. 2: ls -la Purpose: Lists every entry with details, hidden ones too.
Syntax: ls -la [folder]
Example:
$ ls -la Documents
total 16
drwxr-xr-x 2 lerner lerner 4096 Oct 16 18:00 .
drwxr-xr-x 6 lerner lerner 4096 Oct 17 08:58 ..
-rw-r--r-- 1 lerner lerner 141 Oct 16 18:00 notes.txt
-rw-r--r-- 1 lerner lerner 51 Oct 14 10:30 report.txt Output from the simulator, as on a real Linux.
Options:
-l long format: rights, owner, size, time -a also names that start with a dot Remember
A dot in front hides a name, -a shows it again.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 3
Date 10 Nov 2026
Learning goal Terminal Start, lesson 2
Level 1 of 3 Command of the day No. 3: ls -lh Purpose: Shows file sizes in K, M and G.
Syntax: ls -lh [folder]
Example:
$ ls -lh Downloads
total 2.4M
-rw-r--r-- 1 lerner lerner 2.2M Oct 8 16:00 manual.pdf
-rw-r--r-- 1 lerner lerner 147K Oct 15 20:00 photo.jpg
-rwxr-xr-x 1 lerner lerner 26 Oct 12 09:00 setup.sh Output from the simulator, as on a real Linux.
Options:
-h sizes for humans: 147K instead of 150000 -S sorts by size, largest first Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 4
Date 10 Nov 2026
Learning goal Terminal Start, lesson 2
Level 1 of 3 Command of the day No. 4: ls -lt Purpose: Lists entries by time, newest first.
Syntax: ls -lt [folder]
Example:
$ ls -lt Downloads
total 2400
-rw-r--r-- 1 lerner lerner 150000 Oct 15 20:00 photo.jpg
-rwxr-xr-x 1 lerner lerner 26 Oct 12 09:00 setup.sh
-rw-r--r-- 1 lerner lerner 2300000 Oct 8 16:00 manual.pdf Output from the simulator, as on a real Linux.
Options:
-t sorts by the time of the last change -r reverses the order: oldest first Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 5
Date 10 Nov 2026
Learning goal Terminal Start, lesson 3
Level 2 of 3 Command of the day No. 5: cd - Purpose: Jumps back to the folder you were in before.
Syntax: cd -
Example:
$ cd logs
$ cd -
/home/lerner Output from the simulator, as on a real Linux.
Options:
cd .. goes one folder up instead Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter. Press Enter, then type cd - and press Enter again: you are back home. Another cd - takes you to logs.
Link to this card
No. 6
Date 10 Nov 2026
Learning goal Terminal Start, lesson 3
Level 1 of 3 Command of the day No. 6: cd without a target Purpose: Takes you straight home from anywhere.
Syntax: cd
Example:
$ cd logs
$ cd
$ pwd
/home/lerner Output from the simulator, as on a real Linux.
Options:
cd ~ the same, written out: ~ is your home folder Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 7
Date 10 Nov 2026
Learning goal Terminal Start, lesson 4
Level 2 of 3 Command of the day No. 7: mkdir -p Purpose: Creates a folder and every missing folder above it.
Syntax: mkdir -p path/to/folder
Example:
$ mkdir -p projects/site/css
$ ls projects/site
css Output from the simulator, as on a real Linux.
Options:
-p creates parents and does not complain if the folder exists -v names every folder it creates sudo: Outside your home folder, for example in /opt, you need sudo mkdir.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 8
Date 10 Nov 2026
Learning goal Terminal Start, lesson 4
Level 1 of 3 Command of the day No. 8: touch Purpose: Creates an empty file or updates its time.
Syntax: touch file
Example:
$ ls -l todo.txt
-rw-r--r-- 1 lerner lerner 37 Oct 17 08:15 todo.txt
$ touch todo.txt
$ ls -l todo.txt
-rw-r--r-- 1 lerner lerner 37 Oct 17 09:00 todo.txt Output from the simulator, as on a real Linux.
Options:
-c does not create the file if it is missing Caution
On an existing file touch keeps the content but changes the time, so ls -lt and backups see it as new.
Remember
touch never empties a file, it only sets the time.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 9
Date 10 Nov 2026
Learning goal Terminal Start, lesson 6
Level 2 of 3 Command of the day No. 9: cp -i Purpose: Copies, but asks before overwriting a file.
Syntax: cp -i source target
Example:
$ cp -i todo.txt Documents/notes.txt
cp: overwrite 'Documents/notes.txt'? n
$ head -n 1 Documents/notes.txt
Buy milk Output from the simulator, as on a real Linux.
Options:
-i asks before overwriting -r copies folders with everything inside -v names every copied file Caution
Without -i, cp overwrites the target silently and the old content is gone.
Remember
n keeps, y replaces: -i gives you the choice.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter. cp asks before it overwrites: n keeps the old file, y replaces it.
Link to this card
No. 10
Date 10 Nov 2026
Learning goal Terminal Start, lesson 6
Level 1 of 3 Command of the day No. 10: mv to rename Purpose: Gives a file a new name without copying it.
Syntax: mv old-name new-name
Example:
$ mv Documents/report.txt Documents/report-2026.txt
$ ls Documents
notes.txt report-2026.txt Output from the simulator, as on a real Linux.
Options:
-i asks before overwriting -n never overwrites an existing file Caution
If the new name is taken, mv replaces that file without asking.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 11
Date 10 Nov 2026
Learning goal Terminal Start, lesson 7
Level 1 of 3 Command of the day No. 11: ls first, then rm -i Purpose: Look first, then delete with a safety question.
Syntax: ls file, then rm -i file
Example:
$ ls Downloads
manual.pdf photo.jpg setup.sh
$ rm -i Downloads/setup.sh
rm: remove regular file 'Downloads/setup.sh'? y
$ ls Downloads
manual.pdf photo.jpg Output from the simulator, as on a real Linux.
Options:
-i asks before every file -r deletes folders with everything inside sudo: If rm refuses, do not just add sudo: the refusal often protects you.
Remember
Same names for ls and rm: look first, then delete.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter. After the list, type rm -i Downloads/setup.sh. rm asks first: y deletes, n keeps the file.
Link to this card
No. 12
Date 10 Nov 2026
Learning goal Terminal Start, lesson 7
Level 2 of 3 Command of the day No. 12: rmdir Purpose: Deletes a folder, but only when it is empty.
Syntax: rmdir folder
Example:
$ rmdir old
$ rmdir Documents
rmdir: failed to remove 'Documents': Directory not empty Output from the simulator, as on a real Linux.
Options:
-p also removes parent folders that become empty -v names every folder it removes Caution
An empty folder is gone at once, without a question.
Check first
ls -A folder: no output and no error means the folder is empty, hidden files included.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 13
Date 10 Nov 2026
Learning goal Terminal Start, lesson 5
Level 1 of 3 Command of the day No. 13: cat -n Purpose: Shows a file with numbered lines.
Syntax: cat -n file
Example:
$ cat -n todo.txt
1 1. tidy up Downloads
2 2. read the log Output from the simulator, as on a real Linux.
Options:
-n numbers every line -b numbers only lines that are not empty Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 14
Date 10 Nov 2026
Learning goal Terminal Start, lesson 5
Level 1 of 3 Command of the day No. 14: head -n Purpose: Shows only the first lines of a file.
Syntax: head -n number file
Example:
$ head -n 3 Documents/notes.txt
Buy milk
Call the landlord
Water the plants Output from the simulator, as on a real Linux.
Options:
-n 3 the first 3 lines; without -n it shows 10 -c 20 the first 20 bytes Remember
head shows the top, tail the bottom.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 15
Date 10 Nov 2026
Learning goal Terminal Start, lesson 5
Level 1 of 3 Command of the day No. 15: tail -n Purpose: Shows only the last lines of a file.
Syntax: tail -n number file
Example:
$ tail -n 2 logs/app.log
WARN slow response
ERROR payment failed Output from the simulator, as on a real Linux.
Options:
-n 2 the last 2 lines; without -n it shows 10 -f keeps watching and shows new lines (stop with Ctrl-C) Remember
New log entries land at the bottom, tail shows them first.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 16
Date 10 Nov 2026
Learning goal Terminal Start, lesson 5
Level 2 of 3 Command of the day No. 16: less and / Purpose: Reads long files page by page and searches them.
Syntax: less file, then /word and Enter
Example:
$ less Documents/notes.txt
Book train tickets
Return library books
Pay the power bill
Back up the laptop
Fix the bike light
(END) Shows the screen of the program in a terminal 6 lines high.
Options:
/word searches forward, n finds the next hit Space shows the next page q quits less Remember
less only shows, it never changes the file.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter. In less type /laptop and press Enter. n jumps to the next hit, q quits.
Link to this card
No. 17
Date 10 Nov 2026
Learning goal Terminal Start, lesson 11
Level 1 of 3 Command of the day No. 17: wc -l Purpose: Counts the lines of a file.
Syntax: wc -l file
Example:
$ wc -l logs/app.log
8 logs/app.log Output from the simulator, as on a real Linux.
Options:
-l lines -w words -c bytes Remember
wc -l counts lines, behind a pipe it counts anything.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 18
Date 10 Nov 2026
Learning goal Terminal Start, lesson 10
Level 1 of 3 Command of the day No. 18: grep -i Purpose: Finds lines no matter if upper or lower case.
Syntax: grep -i word file
Example:
$ grep -i error logs/app.log
ERROR database timeout
INFO retry after ERROR ok
error cache miss
ERROR payment failed Output from the simulator, as on a real Linux.
Options:
-i ignores upper and lower case -w matches whole words only -c counts the matching lines Remember
With -i, ERROR, Error and error are all the same.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 19
Date 10 Nov 2026
Learning goal Terminal Start, lesson 10
Level 1 of 3 Command of the day No. 19: grep -n Purpose: Finds lines and shows their line numbers.
Syntax: grep -n word file
Example:
$ grep -n WARN logs/app.log
3:WARN disk 85% full
7:WARN slow response Output from the simulator, as on a real Linux.
Options:
-n puts the line number in front -i ignores upper and lower case Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 20
Date 10 Nov 2026
Learning goal Terminal Start, lesson 10
Level 2 of 3 Command of the day No. 20: grep -v Purpose: Shows every line that does not match.
Syntax: grep -v word file
Example:
$ grep -v INFO logs/app.log
WARN disk 85% full
ERROR database timeout
error cache miss
WARN slow response
ERROR payment failed Output from the simulator, as on a real Linux.
Options:
-v turns the match around -c counts instead of showing Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 21
Date 10 Nov 2026
Learning goal Terminal Start, lesson 10
Level 2 of 3 Command of the day No. 21: grep -r Purpose: Searches every file in a folder and below.
Syntax: grep -r word folder
Example:
$ grep -r ERROR logs
logs/app.log:ERROR database timeout
logs/app.log:INFO retry after ERROR ok
logs/app.log:ERROR payment failed
logs/old.log:ERROR disk full Output from the simulator, as on a real Linux.
Options:
-r searches folders recursively -l names only the files with a match -i ignores upper and lower case Remember
With -r, the file name comes first, then the line.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 22
Date 10 Nov 2026
Learning goal Terminal Start, lesson 10
Level 3 of 3 Command of the day No. 22: grep -E '^(ERROR|WARN)' Purpose: Finds lines that start with ERROR or WARN.
Syntax: grep -E 'pattern' file
Example:
$ grep -E '^(ERROR|WARN)' logs/app.log
WARN disk 85% full
ERROR database timeout
WARN slow response
ERROR payment failed Output from the simulator, as on a real Linux.
Options:
-E extended patterns: | means or, ( ) groups ^ the start of a line $ the end of a line Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 23
Date 10 Nov 2026
Learning goal Terminal Start, lesson 10
Level 2 of 3 Command of the day No. 23: find -name Purpose: Finds files by name in every subfolder.
Syntax: find folder -name 'pattern'
Example:
$ find . -name '*.log'
./logs/app.log
./logs/old.log Output from the simulator, as on a real Linux.
Options:
-name name with wildcards like * -iname the same, ignoring upper and lower case sudo: find / searches the whole system; without sudo many folders say Permission denied. 2>/dev/null hides that.
Remember
Quote the pattern, or the shell expands it first.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 24
Date 10 Nov 2026
Learning goal Terminal Start, lesson 10
Level 2 of 3 Command of the day No. 24: find -type d Purpose: Lists only folders, no files.
Syntax: find folder -type d
Example:
$ find . -type d
.
./Documents
./Downloads
./logs
./old Output from the simulator, as on a real Linux.
Options:
-type d folders only -type f regular files only -maxdepth 1 only this level, no deeper Remember
d for directory, f for file.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 25
Date 10 Nov 2026
Learning goal Terminal Start, lesson 11
Level 3 of 3 Command of the day No. 25: sort | uniq -c | sort -rn Purpose: Counts how often each line occurs, most common first.
Syntax: sort file | uniq -c | sort -rn
Example:
$ sort visitors.txt | uniq -c | sort -rn
3 anna
2 ben
1 carla Output from the simulator, as on a real Linux.
Options:
uniq -c counts lines that repeat right after each other sort -rn sorts by number, largest first Remember
uniq only sees neighbors, so always sort first.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 26
Date 10 Nov 2026
Learning goal Terminal Start, lesson 11
Level 3 of 3 Command of the day No. 26: 2>&1 and /dev/null Purpose: Moves error messages elsewhere or makes them vanish.
Syntax: command 2>/dev/null, command 2>&1
Example:
$ ls todo.txt missing.txt
ls: cannot access 'missing.txt': No such file or directory
todo.txt
$ ls todo.txt missing.txt 2>/dev/null
todo.txt
$ ls missing.txt 2>&1 | wc -l
1 Output from the simulator, as on a real Linux.
Options:
2>/dev/null throws error messages away 2>&1 sends errors where the output goes, for example into a pipe Remember
1 is the output, 2 the errors; &1 means channel 1, not a file.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 27
Date 10 Nov 2026
Learning goal Terminal Start, lesson 11
Level 2 of 3 Command of the day No. 27: > against >> Purpose: Writes output into a file: replace or append.
Syntax: command > file, command >> file
Example:
$ echo first > list.txt
$ echo second >> list.txt
$ cat list.txt
first
second
$ echo new > list.txt
$ cat list.txt
new Output from the simulator, as on a real Linux.
Options:
> empties the file, then writes >> appends at the end Caution
> empties the file before the command even runs, so the old content is gone.
Remember
One > replaces, two >> append.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 28
Date 10 Nov 2026
Learning goal Terminal Start, lesson 8
Level 2 of 3 Command of the day No. 28: type and which Purpose: Shows what really runs when you type a command.
Syntax: type name, which name
Example:
$ type cd
cd is a shell builtin
$ type ls
ls is /usr/bin/ls
$ which ls
/usr/bin/ls Output from the simulator, as on a real Linux.
Options:
type -a shows every match in the order bash tries them which -a every program with that name in PATH Distributions: On Debian and Ubuntu, ls is often an alias for colors. type shows that, which does not.
Remember
type knows builtins and aliases, which only searches PATH.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.
Link to this card
No. 29
Date 10 Nov 2026
Learning goal Terminal Start, lesson 9
Level 2 of 3 Command of the day No. 29: Ctrl-R Purpose: Searches your command history backwards while you type.
Syntax: Ctrl-R, then type part of a command
Example:
$ grep -n WARN logs/app.log
3:WARN disk 85% full
7:WARN slow response
$ wc -l logs/app.log
8 logs/app.log
(reverse-i-search)`grep': grep -n WARN logs/app.log Output from the simulator, as on a real Linux.
Options:
Ctrl-R again jumps to the next older match Enter runs the match Ctrl-C cancels the search Remember
Type a piece, get the whole command back.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter. Press Enter so the command is in your history. Then press Ctrl-R and type grep: the line comes back. Enter runs it again.
Link to this card
No. 30
Date 10 Nov 2026
Learning goal Terminal Start, lesson 8
Level 1 of 3 Command of the day No. 30: man and --help Purpose: Opens the manual or a short help for a command.
Syntax: man command, command --help
Example:
$ man ls
NAME
ls - lists what is in a directory
SYNOPSIS
ls [OPTION]... [FILE]...
Manual page ls(1) line 1 (press q to quit) Shows the screen of the program in a terminal 6 lines high.
Options:
q closes the manual /word searches inside the manual --help short help right in the terminal Distributions: Small server and container images often ship without manual pages; --help still works there.
Remember
Stuck? --help for a quick look, man for the details.
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter. In the manual, Space turns the page, /word searches and q quits. For the short version type ls --help.
Link to this card
All cards so far