• We did not send an email asking for donations - please read this post.

When is using a ";" (semi-colon) in a script vital to it?

CrazedNerd

Well-Known Member
Joined
Mar 31, 2021
Messages
822
Reaction score
321
Credits
7,012
I'm currently reading "bash idioms", and i was happy to know that in a script, you don't actually need ; for commands, you can just put the next thing on a line. In this respect it's like python. Are there times when you need to use the semicolon for multiple lines of code?
 


JasKinasis

Well-Known Member
Joined
Apr 25, 2017
Messages
1,570
Reaction score
2,232
Credits
11,611
When you’re trying to run multiple commands on a single line, without entering them as separate lines!
 
$100 Digital Ocean Credit
Get a free VM to test out Linux!

Linux.org Hosting Donations
Consider making a donation

Members online


Top