For Years 8–10: use a computer by typing commands, as people do on servers, Raspberry Pis and Linux and Mac computers. Move around folders, read and search files, change them, chain commands with pipes, and control who can read what. Everything runs on a pretend computer in the browser; a Raspberry Pi is the real thing.
Folders and paths, reading and finding, changing files, pipes, and permissions.
Files live in a tree of folders, and a path names a place in it. pwd says where you are, ls lists what is here and cd moves you, with full paths from the top (/), short paths from where you are, .. for the folder above and ~ for home.
cat prints a whole file and grep prints only the lines that contain a word. Names that start with a dot are hidden: ls skips them, ls -a shows them. With these you can find anything on a computer you can't see.
mkdir makes a folder, cp copies, mv moves or renames, rm deletes and echo … > saves text into a file. rm is for good: there is no recycle bin in a shell, so look before you delete.
A pipe (|) sends one command's output into the next command instead of the screen, so small commands combine: grep finds lines, wc -l counts them, sort puts them in order, uniq drops repeats, head keeps the first few, and > saves the result.
Every file has an owner and permissions: read, write and run, for the owner and for everyone else. ls -l shows them as letters like rw-r--r-- (644). The owner changes them with chmod; nobody else can. Hiding a file protects nothing; permissions do.
Progress is saved in this browser only. Nothing is sent anywhere.
For teachers: Teacher guide (notes, answers, solutions, slides and worksheets)