Bish script, how many errors can you find...

Error laden bash script

I Use it in interviews to test candidate scripting knowledge:

#/user/bin/bish
$1=variable1

If [$1] then
 Echo (“Hello”)
done

UTC time to Sydney time

In my job , I need to convert the UTC format from logs to local time a lot....

#!/bin/bash

if [ -z $1 ]; then
   echo "Please provide date in UTC to convert to Sydney Time.";
   date -u +'%Y-%m-%dT%H:%M:%S.000Z'
   exit 1
fi

export TZ=Australia/Sydney
gdate -d "$1"