Skip to main content

Time Based Utility Tools

Project description

vutime

Time Based Utility Tools for Python

Installation

pip install vutime

Usage

Adding Times

from vutime import add_time

# Add two times in HH:MM:SS format
result = add_time("10:30:43", "07:53:49")
print(result)  # Output: 18:24:32

# Add times with different formats
result = add_time("10:30", "05:45", time_format_1="HH:MM", time_format_2="HH:MM", return_format="HH:MM:SS")
print(result)  # Output: 16:15:00

Subtracting Times

from vutime import subtract_time

# Subtract two times (time1 must be greater than time2)
result = subtract_time("10:30:43", "07:53:49")
print(result)  # Output: 02:36:54

# Subtract times with custom formats
result = subtract_time("10:30", "05:45", time_format_1="HH:MM", time_format_2="HH:MM")
print(result)  # Output: 04:45:00

Format Options

Supported time formats:

  • HH:MM:SS - Hours, minutes, seconds (default)
  • HH:MM - Hours, minutes
  • MM:SS - Minutes, seconds

Requirements

  • Python 3.12+

License

MIT

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

vutime-0.1.0.tar.gz (2.5 kB view details)

Uploaded Source

Built Distribution

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

vutime-0.1.0-py3-none-any.whl (3.5 kB view details)

Uploaded Python 3

File details

Details for the file vutime-0.1.0.tar.gz.

File metadata

  • Download URL: vutime-0.1.0.tar.gz
  • Upload date:
  • Size: 2.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for vutime-0.1.0.tar.gz
Algorithm Hash digest
SHA256 ce7a85da554573d7d2ff0d3ba804489a8f16d1598f6077032e425550f08ae5d3
MD5 315b0769fad9c7fcc263ca6518961370
BLAKE2b-256 95b92e43bb621c178f6d071c24ec0cb15cf797eb889ff6a66bd694bbb7e0c67e

See more details on using hashes here.

File details

Details for the file vutime-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: vutime-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 3.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for vutime-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 89a57c4669cc772621d509eaf6cade4d8151900ccfac01ee7af8f4d30e166698
MD5 d670ad7c58b5788b736f155fc5f16a2a
BLAKE2b-256 7510e4224088df3031b79a000006d4dd409810e785c7500db8b0ac91bb344598

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