Learn › Linux Foundations
Manipulation
Create, copy, move, rename, and remove files and directories. Build and reshape the filesystem.
Labs in this module
- touch - Make a file exist from nothing with touch. It creates empty files, builds several at once, and updates the timestamp on files that already e
- rmdir - Meet rmdir, the safe, narrow delete that removes an empty directory only. It succeeds in silence, so you prove each removal with ls. Its def
- ln - Give one file a second name with ln, a hard link: same inode, same data, no copy. ln is silent on success, so you prove the link with ls -i
- mv - Meet mv, the one command that both moves and renames, because to Linux they are the same act. A new name renames the file; a folder moves it
- realpath - Resolve any path to its one true absolute, canonical form with realpath. It makes paths absolute, collapses . and .., and follows symlinks t
- dirname - Meet dirname, the mirror of basename: it keeps the folder part of a path and drops the final name. dirname /home/student/report.txt prints /
- basename - Strip a path down to its last name with basename. Keep just the file name, drop a suffix with a second argument or with -s, handle a trailin
- readlink - Read where a symbolic link points with readlink. Plain readlink prints the raw target stored in the link; readlink -f canonicalizes, followi
- ln -s - Plant a signpost with ln -s: a symbolic link that stores a PATH to another file, unlike a hard link that shares the inode. The command is si
- mkdir - Make folders on demand with mkdir. It is silent on success, so every drill proves the result with ls. Learn -p to build a whole nested chain
- rm - Remove files and directories with rm, the delete key that has no undo and no Trash. rm is silent on success, so every drill proves the effec
- cp - Copy files and folders with cp. It is silent on success, so every drill runs cp then proves the result with ls or cat. Learn the core cp sou
- The Vault: Operation Archivist - The Manipulation module capstone mission. Drill mkdir, touch, cp, mv, ln -s, rm, rmdir, and the path readers (readlink, realpath, basename,