using a bash script instead