Yeah, wakealarm won't be set if that gives you an error. Unfortunately that's a bug in the 'date' utility, it doesn't recognize "ICT" as a time zone. We can work around that, though. We'll have to just remove the time zone tag from the output of hwclock, since it's actually unnecessary. Try replacing $(sudo hwclock) in that same line with $(sudo hwclock | sed -r 's/[A-Z]+\s+([0-9\.\-]+)/\1/') and see if that works...
Yeah, wakealarm won't be set if that gives you an error. Unfortunately that's a bug in the 'date' utility, it doesn't recognize "ICT" as a time zone. We can work around that, though. We'll have to just remove the time zone tag from the output of hwclock, since it's actually unnecessary. Try replacing $(sudo hwclock) in that same line with $(sudo hwclock | sed -r 's/[A-Z] +\s+([0- 9\.\-]+ )/\1/') and see if that works...