fixed issues with shell script