Bash scripting missing ']' [closed]
Change
if [ -s "p1"]; #line 13
into
if [ -s "p1" ]; #line 13
note the space.
I got this error while trying to use the &&
operator inside single brackets like [ ... && ... ]
. I had to switch to [[ ... && ... ]]
.
You're missing a space after "p1"
:
if [ -s "p1" ];