Linux Terminal Glossary
›
File Operations
File Operations
60 commands
touch file.txt
touch -t 202301011200 file.txt
touch -a file.txt
touch -m file.txt
mkdir mydir
mkdir -p a/b/c
mkdir -m 755 mydir
cp src.txt dst.txt
cp -r srcdir/ dstdir/
cp -p src.txt dst.txt
cp -a srcdir/ dstdir/
cp -u src.txt dst.txt
cp -v src.txt dst.txt
cp -i src.txt dst.txt
cp -n src.txt dst.txt
mv src.txt dst.txt
mv -i src.txt dst.txt
mv -n src.txt dst.txt
mv -v src.txt dst.txt
rm file.txt
rm -r dir/
rm -f file.txt
rm -rf dir/
rm -i file.txt
rm -v file.txt
ln -s /path/to/target linkname
ln /path/to/target hardlink
ln -sf /new/target linkname
readlink -f symlink
rsync -av src/ dst/
rsync -avz src/ user@host:dst/
rsync --delete src/ dst/
rsync -n src/ dst/
rsync --progress src/ dst/
find . -name '*.txt'
find /path -type f
find /path -type d
find . -mtime -7
find . -size +10M
find . -empty
find . -perm 644
find . -user username
find . -name '*.log' -delete
find . -name '*.sh' -exec chmod +x {} \;
locate filename
updatedb
stat file.txt
file file.txt
wc file.txt
wc -l file.txt
wc -w file.txt
wc -c file.txt
diff file1.txt file2.txt
diff -u file1.txt file2.txt
diff -r dir1/ dir2/
cmp file1 file2
patch file.txt < changes.patch
patch -p1 < changes.patch
truncate -s 0 file.txt
shred -u file.txt
Search all 7,657 commands
instead.