Skip to content

Instantly share code, notes, and snippets.

@evnm
Created June 10, 2015 23:39
Show Gist options
  • Save evnm/d17336bf42e887c6e756 to your computer and use it in GitHub Desktop.
Save evnm/d17336bf42e887c6e756 to your computer and use it in GitHub Desktop.
Script to convert milliseconds since epoch to a human-readable timestamp
#!/usr/bin/python
import datetime
import sys
print datetime.datetime.fromtimestamp(float(sys.argv[1])/1000).strftime('%Y-%m-%d %H:%M:%S.%f')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment