Skip to main content

A single function to get a nice date-time format

Project description

neattime

This package includes a simple function to create my preferred date-time format for log files.

The date and time are given in the format yyyy-MM-dd_HH-mm-ss_SSSS

Example:

from neattime import neattime

print(neattime())

output:

'2025-02-26_08-34-13_636609'

How I would actually use it:

from neattime import neattime

filepath = f'save_directory/log_{neattime()}'

# some code that saves my logfile

print(f"File saved to {filepath}")

output:

File saved to save_directory/log_2025-02-26_08-34-13_636609

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

neattime-0.0.3.tar.gz (1.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

neattime-0.0.3-py3-none-any.whl (2.5 kB view details)

Uploaded Python 3

File details

Details for the file neattime-0.0.3.tar.gz.

File metadata

  • Download URL: neattime-0.0.3.tar.gz
  • Upload date:
  • Size: 1.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.1

File hashes

Hashes for neattime-0.0.3.tar.gz
Algorithm Hash digest
SHA256 ef3e87890a0d2eed8e4cdfd14fa88914c27edd7f439b79f591f53c3f0012b1e6
MD5 a3b0b94aad5c9e9decd4a948d656547b
BLAKE2b-256 eff50cd35c8e9c40e9254cd6076d45b7b80ea320955aa578780021102dcb196d

See more details on using hashes here.

File details

Details for the file neattime-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: neattime-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 2.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.1

File hashes

Hashes for neattime-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 6459f663c8d427ce34a1cb9affc6abd6a250b4c8738b317b2fb64b92f7e4ce13
MD5 8a453d82527746dd0e5890de199b0ed7
BLAKE2b-256 c5cc609217c28c3e4eb805935d542a6d6b247cb6a17e01aba6d663edce3eaa85

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