Manuals / Linux & CLI for Testers / Ch 2

A · BasicsBeginner35 min read

2. Navigation & files

Linux & CLI for Testers · 36 pages source format

pwd, ls, cd, mkdir, cp, mv, rm (carefully), find. Paths absolute vs relative.

What you'll learn

  • Paths
  • Listing
  • Safe delete habits

Lab tree

mkdir -p ~/cli-lab/{logs,data,scripts}
echo "hello" > ~/cli-lab/data/sample.txt
cp ~/cli-lab/data/sample.txt ~/cli-lab/data/sample.bak
ls -la ~/cli-lab/**

Do this now

In ~/cli-lab build a small tree, copy, rename, and list recursively.

Pro tip. `rm -rf` is a loaded weapon. Prefer trash tools while learning.

Clear?

Checklist