SC1059
Joachim Ansorg edited this page Oct 31, 2022
·
2 revisions
Semicolon is not allowed directly after do. You can just delete it.
Problematic code:
while true; do; true; done
while true;
do;
true;
done;Correct code:
while true; do true; done
while true;
do
true;
done;Rationale:
Semicolon ; is not allowed directly after a do keyword. Follow it directly with either a command or a linefeed as shown in the example.
Exceptions:
None.
Related resources:
- Help by adding links to BashFAQ, StackOverflow, man pages, POSIX, etc!