Skip to content

mohrezfadaei/multical

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MultiCal: Multi-Calendar Date Converter

MultiCal is a command-line application that converts dates between Jalali (Solar Hijri), Gregorian, and Lunar Hijri (Islamic) calendars. It also provides the current date in different calendar formats with options for JSON, YAML, and table output.


Features

  • Convert between Jalali, Gregorian, and Lunar Hijri calendars
  • Display today’s date in all supported calendar formats
  • Output results in JSON, YAML, or Table format
  • Fast, accurate, and easy-to-use CLI

Installation

Run the following command in your terminal:

bash <(curl -s https://raw.githubusercontent.com/mohrezfadaei/multical/main/install.sh)

Once installed, restart your terminal or run:

source ~/.bashrc  # or source ~/.zshrc if using Zsh

Now, you can run MultiCal using:

multical today --to all

NOTE

If you want to uninstall MultiCal persitantly on your system issue the following commands:

bash <(curl -s https://raw.githubusercontent.com/mohrezfadaei/multical/main/uninstall.sh)

Usage

Convert a Date

multical convert --mode [j2g|g2j|g2l|l2g|j2l|l2j] --year <YYYY> --month <MM> --day <DD> [--format json|yaml|table]
  • j2g → Jalali to Gregorian
  • g2j → Gregorian to Jalali
  • g2l → Gregorian to Lunar Hijri
  • l2g → Lunar Hijri to Gregorian
  • j2l → Jalali to Lunar Hijri
  • l2j → Lunar Hijri to Jalali

Example: Convert Jalali 1403-12-20 to Gregorian

multical convert --mode j2g --year 1403 --month 12 --day 20

Example: Convert and output in JSON

multical convert --mode j2g --year 1403 --month 12 --day 20 --format json

Show Today’s Date in Different Calendars

multical today --to [jalali|gregorian|lunar|all] [--format json|yaml|table]

Example: Show today’s date in all formats

multical today --to all

Example: Show today’s date in YAML format

multical today --to all --format yaml

About

A lightweight CLI tool for converting dates between Jalali, Gregorian, and Lunar Hijri calendars.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published