convert batch to shell script