Last active
June 15, 2020 12:57
-
-
Save aseba/705507243f0331c05d2dd05a1d267c77 to your computer and use it in GitHub Desktop.
Bash Script to print several timezones at once
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#ls /usr/share/zoneinfo/ | |
declare -a Timezones=("America/New_York" "Europe/London" "Europe/Madrid") | |
echo Home: `date +"%m-%d-%Y %T %z"` | |
for tz in ${Timezones[@]}; do | |
echo $tz: `env TZ=$tz date +"%m-%d-%Y %T %z"` | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment