Traverse & Enumerate

cd ..

Move Up One Directory Level.

cd ~

Change to Home Directory.

cd -

Change to Previous Directory.

pushd and popd

Manage directory stack for easy backtracking.

pushd -R <dir>

Enter a directory and push it onto the stack, recursively entering subdirectories.

pwd

Print Working Directory.

tree <dir>

Display Directory Structure.

tree <dir> -d

Only directories.

tree <dir> -L <level>

Limit depth.

tree <dir> -F

Append file type indicators to filenames.

realpath <relative_path>

Resolve Relative Paths.

readlink <symbolic_link>

Display the Target of a Symbolic Link.

Last updated

Was this helpful?