Date Formatter SPCM
A simple Python package to format current dates easily.
Installation
You can install the package using pip:
pip install date_formatter_spcm
Usage
Import the functions from the date_formatter package:
from date_formatter import get_pretty_date, dd_mm_yyyy, mm_dd_yyyy, slash_dd_mm_yyyy, slash_mm_dd_yyyy
# Get the current date in 'Day, Month Date, Year' format
print(get_pretty_date()) # e.g., Monday, July 20, 2026
# Get the current date in 'DD-MM-YYYY' format
print(dd_mm_yyyy()) # e.g., 20-07-2026
# Get the current date in 'MM-DD-YYYY' format
print(mm_dd_yyyy()) # e.g., 07-20-2026
# Get the current date in 'DD/MM/YYYY' format
print(slash_dd_mm_yyyy()) # e.g., 20/07/2026
# Get the current date in 'MM/DD/YYYY' format
print(slash_mm_dd_yyyy()) # e.g., 07/20/2026
from date_formatter import get_past_pretty_date, past_dd_mm_yyyy, past_slash_mm_dd_yyyy
# --- Past Date Functions ---
# Get the date from 5 days ago in 'Day, Month Date, Year' format
print(get_past_pretty_date(5))
# Get the date from 7 days ago in 'DD-MM-YYYY' format
print(past_dd_mm_yyyy(7))
# Get the date from 3 days ago in 'MM/DD/YYYY' format
print(past_slash_mm_dd_yyyy(3))
Features
- get_pretty_date(): Returns the current date like "Monday, July 20, 2026".
- dd_mm_yyyy(): Returns the current date in "DD-MM-YYYY" format.
- mm_dd_yyyy(): Returns the current date in "MM-DD-YYYY" format.
- slash_dd_mm_yyyy(): Returns the current date in "DD/MM/YYYY" format.
- slash_mm_dd_yyyy(): Returns the current date in "MM/DD/YYYY" format.
- get_past_pretty_date(n): Returns the date from n days ago in a pretty format.
- past_dd_mm_yyyy(n): Returns the date from n days ago (DD-MM-YYYY).
- past_mm_dd_yyyy(n): Returns the date from n days ago (MM-DD-YYYY).
- past_slash_dd_mm_yyyy(n): Returns the date from n days ago (DD/MM/YYYY).
- past_slash_mm_dd_yyyy(n): Returns the date from n days ago (MM/DD/YYYY).
How it works
This package is a lightweight wrapper built on top of Python's built-in datetime module to provide human-readable shortcuts for common date formats.
Author
Sara Czasak - sara.p.czasak.m@gmail.com
License
This project is licensed under the MIT License.
Metadata
Release files for date-formatter-spcm 0.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| date_formatter_spcm-0.0.3.tar.gz | 2.6 kB | Without provenance | Details for date_formatter_spcm-0.0.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| date_formatter_spcm-0.0.3-py3-none-any.whl | Python 3 | none | any | Details for date_formatter_spcm-0.0.3-py3-none-any.whl |
Total release size: 5.5 kB
Release files / date_formatter_spcm-0.0.3.tar.gz
| Download URL | date_formatter_spcm-0.0.3.tar.gz |
|---|---|
| Size | 2.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8e50d23b708d5b87779124004d94fe78d54d11f25f7677de15c4873e3aa4ae03
|
|
BLAKE2b-256 checksum How to use checksums |
6357f1601ad6dd995aeb820ce9ada3a449b29661cb083a36a32b6c10e5a94bc4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.10
|
Release files / date_formatter_spcm-0.0.3-py3-none-any.whl
| Download URL | date_formatter_spcm-0.0.3-py3-none-any.whl |
|---|---|
| Size | 2.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3c05e47c3d4f939fd461dadbeda7a12247d5a52fdbc5bf445b00c0d83abaaa35
|
|
BLAKE2b-256 checksum How to use checksums |
59ef77262a81d5d8c85008294d6dd55be30f4bf372f153b935ae567419b81000
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.10
|
Security for date-formatter-spcm 0.0.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.