All three routes to running one script, plus the tracing flag
All three routes to running one script, plus the tracing flag
Answer
sh greet chmod u+x greet ./greet sh -x greet
Line 1 needs only read permission. Line 3 needs the execute bit and the leading ./, because . is not on PATH. Line 4 runs the script with tracing on, printing each line as it executes — the first thing to reach for when a script misbehaves and you cannot see why.
S&K 3e ch12 §12.2–12.3.1