Skip to main content

nama-hari

Utilitas konversi dan analisis nama hari Indonesia, Jawa, Sunda, dan Inggris.

Instalasi

pip install nama-hari

Penggunaan Cepat

from nama_hari import ke_jawa, pasaran, hari_lengkap

ke_jawa("Senin")            # "Senen"
ke_jawa("Minggu")           # "Ahad"
pasaran("2026-10-21")       # "Wage" (contoh, verifikasi kalender Jawa)
hari_lengkap("2026-10-21")  # "Rabu Wage"

Penggunaan via Terminal (CLI)

Setelah instalasi, perintah nama-hari tersedia di terminal:

# Konversi nama hari
nama-hari --konversi Senin --ke jawa
# Output: Senin (jawa) -> Senen

# Info lengkap sebuah tanggal
nama-hari --tanggal 2026-10-21
# Output:
# Tanggal   : 2026-10-21
# Hari      : Rabu
# Pasaran   : Wage
# Lengkap   : Rabu Wage

# Selisih hari
nama-hari --selisih Senin Jumat
# Output: Selisih dari Senin ke Jumat: 4 hari

# Daftar semua hari
nama-hari --daftar jawa

# Hari ini & besok
nama-hari --hari-ini
nama-hari --besok

# Bantuan
nama-hari --help

Fitur

  • Konversi nama hari: Indonesia, Jawa, Sunda, Inggris (dua arah)
  • Normalisasi variasi ejaan: Jum'at, Jumaah, Senen, Rebo, Kemis, Ahad, dll.
  • Hari pasaran Jawa: Legi, Pahing, Pon, Wage, Kliwon
  • Utilitas tanggal: hari dari tanggal, selisih hari, hari ini, besok

Contoh Lengkap

from nama_hari import (
    ke_jawa, ke_sunda, ke_inggris, ke_indonesia,
    pasaran, hari_lengkap, hari_dari_tanggal, selisih,
)

# Konversi antar bahasa
ke_jawa("Rabu")        # "Rebo"
ke_sunda("Jumat")      # "Jumaah"
ke_inggris("Senin")    # "Monday"
ke_indonesia("Ahad")   # "Minggu"

# Hari dari tanggal
hari_dari_tanggal("2026-10-21")  # "Rabu"

# Hari pasaran Jawa
pasaran("2026-10-21")            # "Wage"
hari_lengkap("2026-10-21")       # "Rabu Wage"

# Selisih hari (0-6)
selisih("Senin", "Jumat")        # 4
selisih("Jumat", "Senin")        # 3

Daftar Bahasa yang Didukung

Kode Contoh "Senin" Contoh "Minggu"
indonesia Senin Minggu
jawa Senen Ahad
sunda Senén Minggu
inggris Monday Sunday

Catatan tentang Hari Pasaran

Hari pasaran Jawa (Legi, Pahing, Pon, Wage, Kliwon) berputar dengan siklus 5 hari, berjalan bersamaan dengan siklus 7 hari (minggu) sehingga membentuk siklus 35 hari (selapan). Perhitungan menggunakan anchor date yang wajib diverifikasi dengan kalender Jawa resmi sebelum digunakan untuk keperluan serius.

Development

git clone https://github.com/username/nama-hari.git
cd nama-hari
python -m venv .venv
source .venv/bin/activate   # Windows: .venv\Scripts\activate
pip install -e ".[dev]"
pytest -v

Build & Rilis

python -m build
twine upload --repository testpypi dist/*   # uji di TestPyPI dulu
twine upload dist/*                          # rilis ke PyPI

Lisensi

MIT

Metadata

Release files for nama-hari 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nama-hari 0.2.0
File Size Uploaded Provenance
nama_hari-0.2.0.tar.gz 5.8 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for nama-hari 0.2.0
File Interpreter ABI Platform
nama_hari-0.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 11.7 kB

Release files / nama_hari-0.2.0.tar.gz

Download URL nama_hari-0.2.0.tar.gz
Size 5.8 kB
Tags Source
SHA-256 checksum
How to use checksums
8717e8c45260c02c500e3ac6cc2e542526a3c2e0fbe2c9e765ad5ad9465e8d15
BLAKE2b-256 checksum
How to use checksums
7aa71fab5ee34425e41ee65e93d9b34acf492b4d1369bad04e4bab4bfac40326
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.3

Release files / nama_hari-0.2.0-py3-none-any.whl

Download URL nama_hari-0.2.0-py3-none-any.whl
Size 5.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
94f53bc36550e07d5dbd750ea566bef54f09be983fb5887af94bf14ba6ef0de5
BLAKE2b-256 checksum
How to use checksums
247a9d206391445869193c044bbbe052fafda6045758f386ca5620f8078c9484
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.3

Security for nama-hari 0.2.0

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page