Creating and removing
Esta página precisa de um navegador recente (com suporte a SharedArrayBuffer). Por favor, atualize Chrome, Edge, Firefox ou Safari para a versão mais recente.
English
Making things
mkdirmakes a directory;touchmakes an empty file:
mkdir notes
touch notes/todo.txt
- After these, you have a
notesfolder with an emptytodo.txtinside it.

English
Copying and moving
cpcopies a file;mvmoves (or renames) it. Each ▶ starts from the lesson's files, so this one first makes thenotesfolder to move into:
mkdir notes
cp hello.txt backup.txt
mv backup.txt notes/backup.txt
ls notes
mv old newis also how you rename something — moving it to a new name.
English
Removing — carefully
rmremoves a file. To remove a folder and everything in it, add-r(recursive):
cp hello.txt backup.txt
rm backup.txt
ls
mkdir notes
touch notes/todo.txt
rm -r notes
ls
- ⚠️ There is no recycle bin on the command line.
rmis permanent — always check before you delete.
English
Common mistakes
rmdeletes for good — there is no recycle bin.rm noteson a folder fails: a folder needsrm -r. (Real terminals also havermdir, which removes only an empty folder; this practice terminal does not.)
Explorar
Folders and files
mkdir / touch add to the tree; cd moves where you are.
Dificuldade 1/5 · Moedas 100 + pequeno bônus na primeira conclusão hoje
Make a new folder called notes with mkdir notes. The check then lists the folder to confirm it appeared.
Dificuldade 1/5 · Moedas 100 + pequeno bônus na primeira conclusão hoje
Make a copy of hello.txt named backup.txt using cp.
Dificuldade 1/5 · Moedas 100 + pequeno bônus na primeira conclusão hoje
Tidy up: create an empty file todo.txt with touch, then remove hello.txt with rm. The check lists the folder afterwards.