Last active
February 23, 2017 16:28
-
-
Save awaxa/f7f4693c9601539c087f93631227ff96 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
#!/usr/bin/env bash | |
# set -v | |
export TZ=America/Los_Angeles | |
node -e 'console.log(JSON.stringify({date: (new Date).getTime()}))' | jq '.date/1000 | strftime("%Y-%m-%d %H:%M:%S %Z")' | |
export TZ=America/New_York | |
node -e 'console.log(JSON.stringify({date: (new Date).getTime()}))' | jq '.date/1000 | strftime("%Y-%m-%d %H:%M:%S %Z")' | |
export TZ=UTC | |
node -e 'console.log(JSON.stringify({date: (new Date).getTime()}))' | jq '.date/1000 | strftime("%Y-%m-%d %H:%M:%S %Z")' |
Thanks for the bug report!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Can you show the inputs that jq is getting? Make itEDIT: Never mind, I can reproduce this.