From e03699369d4e991dda08514036db54074c290df2 Mon Sep 17 00:00:00 2001 From: travisby Date: Fri, 12 Sep 2014 11:19:43 -0700 Subject: [PATCH] Fixed spelling mistake --- SC1010.md | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/SC1010.md b/SC1010.md index a103db4..1f4ec58 100644 --- a/SC1010.md +++ b/SC1010.md @@ -1,17 +1,17 @@ -## Use semicolon or linefeed before 'done' (or quote to make it literal). - -### Problematic code: - - for f in *; do echo "$f" done - -### Correct code: - - for f in *; do echo "$f"; done - -### Rationale: - -`done` only works as a keyword when it's the first token of the command. If added after a command, it will just be the literal word "done". - -### Contraindications - +## Use semicolon or linefeed before 'done' (or quote to make it literal). + +### Problematic code: + + for f in *; do echo "$f" done + +### Correct code: + + for f in *; do echo "$f"; done + +### Rationale: + +`done` only works as a keyword when it's the first token of the command. If added after a command, it will just be the literal word "done". + +### Contradictions + If you're intentionally using `done` as a literal, you can quote it to make this clear to shellcheck and human readers, e.g. instead of `echo Task is done`, use `echo "Task is done"`. \ No newline at end of file