sudo apt install tree rsync zip unzip p7zip-full acl
Most core file tools come from GNU coreutils and are installed by default.
Commands, distributions, and practical Linux guidance
Command hub
Core file and directory operations for users moving from CMD or PowerShell to Linux shells.
Distro notes
File Management
sudo apt install tree rsync zip unzip p7zip-full acl
Most core file tools come from GNU coreutils and are installed by default.
sudo dnf install tree rsync zip unzip p7zip acl
Core commands are the same; optional tools use dnf package names.
sudo pacman -S tree rsync zip unzip p7zip acl
Minimal installs may lack convenience tools until you install them.
Guides
76 mappings · 28 expanded guides
7z a→7z a archive.7z folder/
Archives & Compression
Create a 7-Zip archive
Creates 7z, ZIP and other supported archive formats with the 7-Zip command-line tool.
Distro equivalents
Debian/Ubuntu
7z a archive.7z folder/
Fedora
7z a archive.7z folder/
Arch
7z a archive.7z folder/
Open expanded guide →
7z x→7z x archive.7z
Archives & Compression
Extract a 7-Zip archive
Extracts 7z, ZIP, RAR and many other archive formats while preserving directory paths.
Distro equivalents
Debian/Ubuntu
7z x archive.7z
Fedora
7z x archive.7z
Arch
7z x archive.7z
Open expanded guide →
Compress-Archive→zip -r archive.zip folder/
Archives & Compression
Create a ZIP archive
Compresses files or folders into a standard ZIP archive.
Distro equivalents
Debian/Ubuntu
zip -r archive.zip folder/
Fedora
zip -r archive.zip folder/
Arch
zip -r archive.zip folder/
Open expanded guide →
Expand-Archive→unzip archive.zip
Archives & Compression
Extract a ZIP archive
Extracts files from a ZIP archive into the current directory or a chosen destination.
Distro equivalents
Debian/Ubuntu
unzip archive.zip
Fedora
unzip archive.zip
Arch
unzip archive.zip
Open expanded guide →
compact /c→gzip file.log
Archives & Compression
Compress individual files
Compresses individual files using gzip or xz to reduce their stored size.
Distro equivalents
Debian/Ubuntu
gzip file.log
Fedora
gzip file.log
Arch
gzip file.log
Open expanded guide →
compact /u→gunzip file.log.gz
Archives & Compression
Decompress individual files
Restores files previously compressed with gzip or xz.
Distro equivalents
Debian/Ubuntu
gunzip file.log.gz
Fedora
gunzip file.log.gz
Arch
gunzip file.log.gz
Open expanded guide →
expand cabinet file→cabextract file.cab
Quick reference
Archives & Compression
Extract CAB archive
Extracts Microsoft cabinet archives on Linux.
Distro equivalents
Debian/Ubuntu
cabextract file.cab
Fedora
cabextract file.cab
Arch
cabextract file.cab
Open quick reference →
gzip file→gzip -k file
Quick reference
Archives & Compression
Compress with gzip
Creates a .gz file while optionally keeping the original.
Distro equivalents
Debian/Ubuntu
gzip -k file
Fedora
gzip -k file
Arch
gzip -k file
Open quick reference →
tar.exe -cf→tar -cf archive.tar folder/
Archives & Compression
Create a TAR archive
Combines files and directories into a TAR archive without necessarily compressing them.
Distro equivalents
Debian/Ubuntu
tar -cf archive.tar folder/
Fedora
tar -cf archive.tar folder/
Arch
tar -cf archive.tar folder/
Open expanded guide →
tar.exe -tf→tar -tf archive.tar
Quick reference
Archives & Compression
List tar archive contents
Lists files inside a tar archive without extracting it.
Distro equivalents
Debian/Ubuntu
tar -tf archive.tar
Fedora
tar -tf archive.tar
Arch
tar -tf archive.tar
Open quick reference →
tar.exe -xf→tar -xf archive.tar
Archives & Compression
Extract a TAR archive
Extracts TAR, tar.gz, tar.xz and other tar-based archives.
Distro equivalents
Debian/Ubuntu
tar -xf archive.tar
Fedora
tar -xf archive.tar
Arch
tar -xf archive.tar
Open expanded guide →
unzip -l on Windows→unzip -l archive.zip
Quick reference
Archives & Compression
List zip archive contents
Lists files in a zip without extracting them.
Distro equivalents
Debian/Ubuntu
unzip -l archive.zip
Fedora
unzip -l archive.zip
Arch
unzip -l archive.zip
Open quick reference →
xz file→xz -T0 file
Quick reference
Archives & Compression
Compress with xz
Creates a high-compression .xz file using available CPU threads.
Distro equivalents
Debian/Ubuntu
xz -T0 file
Fedora
xz -T0 file
Arch
xz -T0 file
Open quick reference →
zip recursive folder→zip -r archive.zip folder
Quick reference
Archives & Compression
Create recursive zip
Compresses a folder tree into a zip file.
Distro equivalents
Debian/Ubuntu
zip -r archive.zip folder
Fedora
zip -r archive.zip folder
Arch
zip -r archive.zip folder
Open quick reference →
attrib +h→mv file .file
Quick reference
Attributes
Hide a file
Linux hides files by naming them with a leading dot.
Distro equivalents
Debian/Ubuntu
mv file .file
Fedora
mv file .file
Arch
mv file .file
Open quick reference →
comp→cmp file1 file2
Quick reference
Compare
Compare binary files
Compares files byte-for-byte and reports the first difference.
Distro equivalents
Debian/Ubuntu
cmp file1 file2
Fedora
cmp file1 file2
Arch
cmp file1 file2
Open quick reference →
fc /b→cmp file1 file2
Quick reference
Compare
Binary file compare
Compares two files as binary data.
Distro equivalents
Debian/Ubuntu
cmp file1 file2
Fedora
cmp file1 file2
Arch
cmp file1 file2
Open quick reference →
copy /y→cp -f source destination
Quick reference
Copy/Move
Copy and overwrite
Copies while forcing overwrite of the target.
Distro equivalents
Debian/Ubuntu
cp -f source destination
Fedora
cp -f source destination
Arch
cp -f source destination
Open quick reference →
move /y→mv -f source destination
Quick reference
Copy/Move
Move and overwrite
Moves while forcing overwrite of the target.
Distro equivalents
Debian/Ubuntu
mv -f source destination
Fedora
mv -f source destination
Arch
mv -f source destination
Open quick reference →
robocopy /e→rsync -a source/ destination/
Quick reference
Copy/Move
Robust recursive copy
Mirrors a directory tree without deleting extra target files.
Distro equivalents
Debian/Ubuntu
rsync -a source/ destination/
Fedora
rsync -a source/ destination/
Arch
rsync -a source/ destination/
Open quick reference →
robocopy /mir→rsync -a --delete source/ destination/
Quick reference
Copy/Move
Mirror directories
Synchronizes a destination so it matches the source.
Distro equivalents
Debian/Ubuntu
rsync -a --delete source/ destination/
Fedora
rsync -a --delete source/ destination/
Arch
rsync -a --delete source/ destination/
Open quick reference →
robocopy /xo→rsync -au source/ destination/
Quick reference
Copy/Move
Skip older source files
Copies only files that are newer than existing destination files.
Distro equivalents
Debian/Ubuntu
rsync -au source/ destination/
Fedora
rsync -au source/ destination/
Arch
rsync -au source/ destination/
Open quick reference →
robocopy /z→rsync -a --partial --progress source/ destination/
Quick reference
Copy/Move
Resume interrupted copy
Keeps partial transfers and shows transfer progress.
Distro equivalents
Debian/Ubuntu
rsync -a --partial --progress source/ destination/
Fedora
rsync -a --partial --progress source/ destination/
Arch
rsync -a --partial --progress source/ destination/
Open quick reference →
xcopy /d→rsync -au source/ destination/
Quick reference
Copy/Move
Copy only newer files
Copies files only when the source is newer than the target.
Distro equivalents
Debian/Ubuntu
rsync -au source/ destination/
Fedora
rsync -au source/ destination/
Arch
rsync -au source/ destination/
Open quick reference →
xcopy /e→cp -a source_dir destination_dir
Quick reference
Copy/Move
Copy directory tree
Copies folders recursively while preserving common metadata.
Distro equivalents
Debian/Ubuntu
cp -a source_dir destination_dir
Fedora
cp -a source_dir destination_dir
Arch
cp -a source_dir destination_dir
Open quick reference →
del /q→rm -f file
Quick reference
Deletion
Delete without prompting
Removes a file without interactive confirmation.
Distro equivalents
Debian/Ubuntu
rm -f file
Fedora
rm -f file
Arch
rm -f file
Open quick reference →
del /s→find . -name "PATTERN" -type f -delete
Quick reference
Deletion
Delete recursively by pattern
Finds matching files under a tree and deletes them.
Distro equivalents
Debian/Ubuntu
find . -name "PATTERN" -type f -delete
Fedora
find . -name "PATTERN" -type f -delete
Arch
find . -name "PATTERN" -type f -delete
Open quick reference →
sdelete file→shred -u file
Quick reference
Deletion
Secure-delete a file
Overwrites and removes a file when secure deletion is appropriate.
Distro equivalents
Debian/Ubuntu
shred -u file
Fedora
shred -u file
Arch
shred -u file
Open quick reference →
dir /a→ls -la
Quick reference
Directory Listing
Show all files
Lists hidden and non-hidden files.
Distro equivalents
Debian/Ubuntu
ls -la
Fedora
ls -la
Arch
ls -la
Open quick reference →
dir /o:n→ls | sort
Quick reference
Directory Listing
Sort directory listing by name
Sorts file names alphabetically.
Distro equivalents
Debian/Ubuntu
ls | sort
Fedora
ls | sort
Arch
ls | sort
Open quick reference →
dir /o:s→ls -lS
Quick reference
Directory Listing
Sort directory listing by size
Shows large files first.
Distro equivalents
Debian/Ubuntu
ls -lS
Fedora
ls -lS
Arch
ls -lS
Open quick reference →
dir /q→ls -l
Quick reference
Directory Listing
Show file owner
Displays owner and group in a long listing.
Distro equivalents
Debian/Ubuntu
ls -l
Fedora
ls -l
Arch
ls -l
Open quick reference →
assoc / ftype (file extension to program)→xdg-mime
File System
Manage file type associations
Views or changes which application opens files of a particular type.
Distro equivalents
Debian/Ubuntu
xdg-mime
Fedora
xdg-mime
Arch
xdg-mime
Open expanded guide →
cd→cd
File System
Change directory
Navigates between directories. Same command name, but with important differences in path notation.
Distro equivalents
Debian/Ubuntu
cd
Fedora
cd
Arch
cd
Open expanded guide →
copy→cp
File System
Copy files and folders
Copies files or entire directory trees to another location.
Distro equivalents
Debian/Ubuntu
cp
Fedora
cp
Arch
cp
Open expanded guide →
copy con→cat > filename
File System
Create a file from keyboard input
Lets you type content directly into a new file from the terminal, without opening an editor.
Distro equivalents
Debian/Ubuntu
cat > filename
Fedora
cat > filename
Arch
cat > filename
Open expanded guide →
del / erase→rm
File System
Delete files and folders
Removes files or directories. Be very careful — Linux has no Recycle Bin by default.
Distro equivalents
Debian/Ubuntu
rm
Fedora
rm
Arch
rm
Open expanded guide →
dir→ls -la
File System
List directory contents
Lists files and folders in the current (or specified) directory.
Distro equivalents
Debian/Ubuntu
ls -la
Fedora
ls -la
Arch
ls -la
Open expanded guide →
dir /b→ls -1
File System
List names only
Prints one file or directory name per line without detailed metadata.
Distro equivalents
Debian/Ubuntu
ls -1
Fedora
ls -1
Arch
ls -1
Open expanded guide →
fsutil file createnew→truncate -s 100M test.img
File System
Create a file of a chosen size
Creates an empty or preallocated file with a specific size.
Distro equivalents
Debian/Ubuntu
truncate -s 100M test.img
Fedora
truncate -s 100M test.img
Arch
truncate -s 100M test.img
Open expanded guide →
mkdir→mkdir
File System
Create new directories
Creates one or more new directories. Same name, but with a useful extra flag.
Distro equivalents
Debian/Ubuntu
mkdir
Fedora
mkdir
Arch
mkdir
Open expanded guide →
mklink→ln -s
File System
Create symbolic and hard links
Creates symbolic links (shortcuts) or hard links pointing to files or directories.
Distro equivalents
Debian/Ubuntu
ln -s
Fedora
ln -s
Arch
ln -s
Open expanded guide →
more→less
File System
Page through large files
Displays large text files one screen at a time, allowing you to scroll up and down.
Distro equivalents
Debian/Ubuntu
less
Fedora
less
Arch
less
Open expanded guide →
move→mv
File System
Move or rename files
Moves files to a new location, or renames them. In Linux, renaming IS moving.
Distro equivalents
Debian/Ubuntu
mv
Fedora
mv
Arch
mv
Open expanded guide →
pushd / popd→pushd / popd
File System
Save and restore directory location
Saves your current directory to a stack so you can jump back to it later after navigating elsewhere.
Distro equivalents
Debian/Ubuntu
pushd / popd
Fedora
pushd / popd
Arch
pushd / popd
Open expanded guide →
rd / rmdir→rmdir / rm -r
File System
Remove directories
Deletes empty directories (rmdir) or directories with all their contents (rm -r).
Distro equivalents
Debian/Ubuntu
rmdir / rm -r
Fedora
rmdir / rm -r
Arch
rmdir / rm -r
Open expanded guide →
ren / rename→mv / rename
File System
Rename files
Renames a file or batch-renames multiple files matching a pattern.
Distro equivalents
Debian/Ubuntu
mv / rename
Fedora
mv / rename
Arch
mv / rename
Open expanded guide →
robocopy→rsync -avh source/ destination/
File System
Synchronize directory trees
Copies and synchronizes directories efficiently, transferring only changed content when possible.
Distro equivalents
Debian/Ubuntu
rsync -avh source/ destination/
Fedora
rsync -avh source/ destination/
Arch
rsync -avh source/ destination/
Open expanded guide →
subst→sudo mount --bind /source /mountpoint
File System
Map a directory to another path
Makes an existing directory tree accessible at a second mount point.
Distro equivalents
Debian/Ubuntu
sudo mount --bind /source /mountpoint
Fedora
sudo mount --bind /source /mountpoint
Arch
sudo mount --bind /source /mountpoint
Open expanded guide →
tree→tree
File System
Display directory tree
Shows the directory structure as a visual tree. May need to be installed on Linux.
Distro equivalents
Debian/Ubuntu
tree
Fedora
tree
Arch
tree
Open expanded guide →
type→cat
File System
Display file contents
Shows the contents of a text file in the terminal. Also used to combine files.
Distro equivalents
Debian/Ubuntu
cat
Fedora
cat
Arch
cat
Open expanded guide →
xcopy→rsync -av
File System
Advanced copy with sync & progress
Copies directories with more control than cp — supports sync, progress display, resume, and remote copying.
Distro equivalents
Debian/Ubuntu
rsync -av
Fedora
rsync -av
Arch
rsync -av
Open expanded guide →
fsutil hardlink create→ln existing_file hardlink_name
Quick reference
Links
Create hard link
Creates another directory entry pointing to the same file inode.
Distro equivalents
Debian/Ubuntu
ln existing_file hardlink_name
Fedora
ln existing_file hardlink_name
Arch
ln existing_file hardlink_name
Open quick reference →
mklink /D→ln -s target link_name
Quick reference
Links
Create directory symlink
Creates a symbolic link to a directory.
Distro equivalents
Debian/Ubuntu
ln -s target link_name
Fedora
ln -s target link_name
Arch
ln -s target link_name
Open quick reference →
mklink /H→ln target hardlink_name
Quick reference
Links
Create file hard link
Creates a Linux hard link for a regular file.
Distro equivalents
Debian/Ubuntu
ln target hardlink_name
Fedora
ln target hardlink_name
Arch
ln target hardlink_name
Open quick reference →
mklink /J→mount --bind /real/path /mount/path
Quick reference
Links
Create junction-like bind mount
Uses a bind mount for a directory-to-directory mapping.
Distro equivalents
Debian/Ubuntu
mount --bind /real/path /mount/path
Fedora
mount --bind /real/path /mount/path
Arch
mount --bind /real/path /mount/path
Open quick reference →
PowerShell Join-Path→printf "%s/%s\n" "$dir" "$name"
Quick reference
Paths
Join path components
Combines directory and filename strings in shell scripts.
Distro equivalents
Debian/Ubuntu
printf "%s/%s\n" "$dir" "$name"
Fedora
printf "%s/%s\n" "$dir" "$name"
Arch
printf "%s/%s\n" "$dir" "$name"
Open quick reference →
PowerShell Split-Path→dirname /path/to/file
Quick reference
Paths
Return parent path
Prints the directory portion of a path.
Distro equivalents
Debian/Ubuntu
dirname /path/to/file
Fedora
dirname /path/to/file
Arch
dirname /path/to/file
Open quick reference →
PowerShell Split-Path -Leaf→basename /path/to/file
Quick reference
Paths
Return filename from path
Prints the final component of a path.
Distro equivalents
Debian/Ubuntu
basename /path/to/file
Fedora
basename /path/to/file
Arch
basename /path/to/file
Open quick reference →
cd with current path→pwd
Quick reference
Paths
Print current directory
Shows the current working directory, similar to checking the current folder in CMD.
Distro equivalents
Debian/Ubuntu
pwd
Fedora
pwd
Arch
pwd
Open quick reference →
PowerShell Get-Acl→getfacl file
Quick reference
Permissions
Show ACL permissions
Displays POSIX ACLs where ACL support is enabled.
Distro equivalents
Debian/Ubuntu
getfacl file
Fedora
getfacl file
Arch
getfacl file
Open quick reference →
PowerShell Set-Acl→setfacl -m u:USER:rw file
Quick reference
Permissions
Set ACL permissions
Modifies POSIX ACL entries for users or groups.
Distro equivalents
Debian/Ubuntu
setfacl -m u:USER:rw file
Fedora
setfacl -m u:USER:rw file
Arch
setfacl -m u:USER:rw file
Open quick reference →
icacls /grant→setfacl -m u:USER:rwx file
Quick reference
Permissions
Grant ACL permissions
Grants explicit permissions to a user.
Distro equivalents
Debian/Ubuntu
setfacl -m u:USER:rwx file
Fedora
setfacl -m u:USER:rwx file
Arch
setfacl -m u:USER:rwx file
Open quick reference →
icacls /reset→setfacl -b file
Quick reference
Permissions
Reset ACL entries
Removes extended ACL entries from a file.
Distro equivalents
Debian/Ubuntu
setfacl -b file
Fedora
setfacl -b file
Arch
setfacl -b file
Open quick reference →
icacls file→getfacl file
Quick reference
Permissions
View file ACLs
Shows detailed access-control entries.
Distro equivalents
Debian/Ubuntu
getfacl file
Fedora
getfacl file
Arch
getfacl file
Open quick reference →
takeown /r→sudo chown -R USER:GROUP path
Quick reference
Permissions
Take ownership recursively
Changes owner and group recursively.
Distro equivalents
Debian/Ubuntu
sudo chown -R USER:GROUP path
Fedora
sudo chown -R USER:GROUP path
Arch
sudo chown -R USER:GROUP path
Open quick reference →
PowerShell Copy-Item→cp source destination
Quick reference
PowerShell File Cmdlets
Copy a file
Copies files from one path to another.
Distro equivalents
Debian/Ubuntu
cp source destination
Fedora
cp source destination
Arch
cp source destination
Open quick reference →
PowerShell Copy-Item -Recurse→cp -r source_dir destination_dir
Quick reference
PowerShell File Cmdlets
Copy folders recursively
Copies a directory and its contents.
Distro equivalents
Debian/Ubuntu
cp -r source_dir destination_dir
Fedora
cp -r source_dir destination_dir
Arch
cp -r source_dir destination_dir
Open quick reference →
PowerShell Get-ChildItem -Force→ls -la
Quick reference
PowerShell File Cmdlets
List files including hidden files
Shows normal and hidden dotfiles with detailed metadata.
Distro equivalents
Debian/Ubuntu
ls -la
Fedora
ls -la
Arch
ls -la
Open quick reference →
PowerShell Get-ChildItem -Recurse→find .
Quick reference
PowerShell File Cmdlets
Recursively list files
Walks a directory tree and prints matching files and folders.
Distro equivalents
Debian/Ubuntu
find .
Fedora
find .
Arch
find .
Open quick reference →
PowerShell Get-Location→pwd
Quick reference
PowerShell File Cmdlets
Show current directory
Prints the absolute path of the current working directory.
Distro equivalents
Debian/Ubuntu
pwd
Fedora
pwd
Arch
pwd
Open quick reference →
PowerShell Move-Item→mv source destination
Quick reference
PowerShell File Cmdlets
Move files or folders
Moves or renames paths.
Distro equivalents
Debian/Ubuntu
mv source destination
Fedora
mv source destination
Arch
mv source destination
Open quick reference →
PowerShell Remove-Item→rm file
Quick reference
PowerShell File Cmdlets
Remove a file
Deletes a file from the filesystem.
Distro equivalents
Debian/Ubuntu
rm file
Fedora
rm file
Arch
rm file
Open quick reference →
PowerShell Remove-Item -Recurse -Force→rm -rf directory
Quick reference
PowerShell File Cmdlets
Force-remove a folder tree
Deletes a directory tree without prompting.
Distro equivalents
Debian/Ubuntu
rm -rf directory
Fedora
rm -rf directory
Arch
rm -rf directory
Open quick reference →
PowerShell Rename-Item→mv old_name new_name
Quick reference
PowerShell File Cmdlets
Rename a file
Renames a file or directory.
Distro equivalents
Debian/Ubuntu
mv old_name new_name
Fedora
mv old_name new_name
Arch
mv old_name new_name
Open quick reference →
PowerShell Set-Location→cd /path/to/folder
Quick reference
PowerShell File Cmdlets
Change directory
Moves the shell into another directory.
Distro equivalents
Debian/Ubuntu
cd /path/to/folder
Fedora
cd /path/to/folder
Arch
cd /path/to/folder
Open quick reference →