; mean in single line scripts like this:
while true; do sudo -n true; sleep 60; kill -0 '$$' || exit; done 2>/dev/null &
Does it mean new line, or "next command"?
It's a separator of commands. Though in the first instance, it might be better to think of it as ending the
For example, if you wanted to do a loop while some command returns success, you would do something like
The semicolon is used to indicate the end of the arguments to
However you can use newlines instead of the semicolon. The following would be exactly equivalent to the example above, just without any semicolons
In fact with bash, if you run the above command, and then after it finishes (or you CTRL+C it), if you go back in history (up arrow keys or whatnot), you'll notice it replaces the multi-line command with one using semicolons instead.
So yes, the syntax for things like