Learn to create directories with mkdir
, including nested ones, and follow best practices for naming files and folders.
Use nano
to create and edit a plain text file from the command line, and understand how to save and exit properly.
touch
CommandCreate empty files quickly using touch
and learn about filename extensions and conventions.
mv
Rename files or move them between directories using mv
, and understand how to avoid overwriting files.
cp
Duplicate files or entire directories with cp
, using the -r
flag for recursive copies and comparing it with mv
.
rm
Safely delete files and folders using rm
and rm -r
, and learn about the risks of permanent deletion without recovery.
Use wildcards like *
and ?
to copy or list many files at once, and practice organizing and reproducing complex folder structures.
cp [old] [new]
copies a file.mkdir [path]
creates a new directory.mv [old] [new]
moves (renames) a file or directory.rm [path]
removes (deletes) a file.*
matches zero or more characters in a filename, so *.txt
matches all files ending in .txt
.?
matches any single character in a filename, so ?.txt
matches a.txt
but not any.txt
.Ctrl-X
, Control-X
, and ^X
.something.extension
. The extension isn’t required and doesn’t guarantee anything, but is normally used to indicate the type of data in the file.