Skip to main content

A simple python-based command-line utility to convert time or date stamps to epoch and back.

Project description

pyepoch

A simple python-based command-line utility to convert time or date stamps to epoch and back.

Usage

pyepoch is installed as a command-line utility accessible as epoch from the command-line.

You can use it to convert time or date string formats to epoch timestamps (with milliseconds):

-$ epoch '2018/1/1'
1514764800000

or if you specify, in seconds:

-$ epoch '2018/1/1' -s
1514764800

You can specify a timestamp as exact and detailed as you want it to. Additionally you can always convert back the epoch timestamp to an iso formatted date string:

-$ epoch 1514764800000
2018-01-01T00:00:00

if your epoch input is in seconds you can add a -s flag, the tool can't determine this automatically.

Bugs

Feel free to report issues, this 'utility' was build out of ease as I got frustrated with manual conversion of timestamps and strings the whole time.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyepoch-0.0.5.tar.gz (2.6 kB view details)

Uploaded Source

File details

Details for the file pyepoch-0.0.5.tar.gz.

File metadata

  • Download URL: pyepoch-0.0.5.tar.gz
  • Upload date:
  • Size: 2.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3

File hashes

Hashes for pyepoch-0.0.5.tar.gz
Algorithm Hash digest
SHA256 a8138a2cb9778a269c022706013793e711e3e278adb7805fc89a8a05bca95f49
MD5 5394daa2581ba3d9842a6b5f8a93c065
BLAKE2b-256 5af4e29e03d912e17f1751091dd281408b6ee83f6c02098b2ced9d6912d7abda

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page