Hello Michael,
Hello,
NACK.
I get your intention with this, but I do not think that the result is usable.
It is a simple as that nobody ends a line with a ; in shell. I do not want to edit the script that way in the future. This is not how people write shell.
Since there are some lines ending with a semicolon in the script, I guess it makes more sense to adjust these now, so we stay consistent in general.
There might be some unquoted variables in this, but I really cannot find them in this patch.
Okay, I will hand in another patch for them, so they are clearly visible.
I think there is a much bigger value in manually auditing code and understand what it does and if it does it in the right way. A lexical analysis does not improve quality.
The script consists of almost 1950 lines. You are certainly right, but an automated analysis seemed to be the only way we can improve code quality a bit - as a full analysis requires too much time.
What you are doing here is making this compatible with other shells which will never be called because the first line says #!/bin/bash. At the end of the day, this script does not even need to be portable because it won’t run on any other platforms apart from Linux.
Okay.
-Michael
Thanks, and best regards, Peter Müller