Skip to content

Latest commit

 

History

History
65 lines (52 loc) · 1.01 KB

readme.md

File metadata and controls

65 lines (52 loc) · 1.01 KB

uts

Simple Unix timestamp to human readable date converter. Convert unix timestamp in seconds or nanoseconds to RFC1123 format.

Install

go install github.com/dartt0n/uts@latest

Usage

Usage: uts <unix timestamp>

seconds precision

$ uts 1724692825
> Mon, 26 Aug 2024 20:20:25 UTC

milliseconds precision

$ uts 1724858701000
> Wed, 28 Aug 2024 18:25:01 UTC

microseconds precision

$ uts 1724858701000000
> Wed, 28 Aug 2024 18:25:01 UTC

nanoseconds precision

$ uts 1723140436809000000
> Thu, 08 Aug 2024 21:07:16 UTC

float seconds precision

$ uts 1724692825.123456789
> Mon, 26 Aug 2024 20:20:25 MSK

pipe from stdin

$ echo 1724692825 | uts
> Mon, 26 Aug 2024 20:20:25 UTC

Development

Tools

Run

just run

Test

just test