Minor shell scripts fixes

I did some pass over the shell scripts and brought some
tiny improvements