Decoding Unix Timestamps
Working with Stripe means dealing with Unix timestamps: the ones represented as seconds from Jan 1st 1970. I've been relying on various websites to convert them into something I can understand, which involved a lot of clicking around the browser, not to mention dealing with ads. I also wanted something that'll work without requiring launching or switching apps, since I'm usually looking at timestamps while trying to work on something else.
So one day I finally got around to writing a macro to do this. Here it is in full:
The JavaScript portion is as follows:
To use, simply select your Unix timestamp, and invoking the macro. It'll copy the selected timestamp into the pasteboard, convert it to human readable timestamps in both the local time-zone and in UTC, and show it in a dialog.
And that's pretty much it. Obviously not complicated, yet I've been finding myself using it quite a lot recently. Hope you find it just as useful as I have.
Last updated