Metadata-Version: 2.1
Name: jewcal
Version: 0.8.0
Summary: Convert Gregorian to Jewish dates with holidays and zmanim (Diaspora/Israel).
Author: essel-dev
License: MIT License
        
        Copyright (c) 2022 essel-dev
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
        
Project-URL: Bug Tracker, https://github.com/essel-dev/jewcal/issues
Project-URL: Changelog, https://github.com/essel-dev/jewcal/releases
Project-URL: Documentation, https://jewcal.readthedocs.io/
Project-URL: GitHub, https://github.com/essel-dev/jewcal
Keywords: jewish calendar,hebrew calendar,zmanim
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Utilities
Classifier: Typing :: Typed
Requires-Python: >=3.10
Description-Content-Type: text/x-rst
License-File: LICENSE
Requires-Dist: astral>=3.2
Provides-Extra: dev
Requires-Dist: pre-commit; extra == "dev"
Requires-Dist: tox; extra == "dev"
Requires-Dist: sphinx; extra == "dev"
Requires-Dist: sphinx-rtd-theme; extra == "dev"

.. include_title_start

JewCal
======

.. include_title_end



.. image:: https://github.com/essel-dev/jewcal/actions/workflows/tests.yml/badge.svg
    :target: https://github.com/essel-dev/jewcal/actions/workflows/tests.yml
    :alt: Tests Status
.. image:: https://github.com/essel-dev/jewcal/actions/workflows/pypi.yml/badge.svg
    :target: https://github.com/essel-dev/jewcal/actions/workflows/pypi.yml
    :alt: PyPi Status
.. image:: https://readthedocs.org/projects/jewcal/badge/?version=latest
    :target: https://jewcal.readthedocs.io/en/latest/?badge=latest
    :alt: Documentation Status

|



.. include_intro_start

Convert Gregorian to Jewish dates with holidays and zmanim (Diaspora/Israel).

Get info about:

* The Jewish date
* Shabbos and Yom Tov events
* The action (`Candles` or `Havdalah`)
* The zmanim

  * Sunrise
  * Sunset
  * Plag Hamincha
  * Hadlokas Haneiros (adjust the minutes before sunset)
  * Tzeis (adjust to stars or minutes after sunset)


Determine whether it is:

* Erev Shabbos or Erev Yom Tov
* Shabbos
* Yom Tov
* Issur Melacha

If latitude and longitude are specified, nightfall is taken into account to calculate
the Jewish date.


.. include_intro_end



.. include_quickstart_start

Quickstart
----------

Install JewCal using pip:

.. code-block:: bash

  pip install jewcal


Run in the console:

.. code-block:: bash

  jewcal


The output:

.. code-block:: console

  Today is 23 Iyar 5784

  today.has_events()=True
  today.is_erev()=True
  today.is_erev_shabbos()=True
  today.is_shabbos()=False
  today.is_erev_yomtov()=False
  today.is_yomtov()=False
  today.is_issur_melacha()=False

  JewCal(
    jewish_date=JewishDate(
      year=5784, month=2, day=23,
      gregorian_date=datetime.date(2024, 5, 31)
    ),
    events=Events(
      shabbos='Erev Shabbos',
      yomtov=None,
      action='Candles'
    ),
    diaspora=True,
    zmanim=None
  )


  Zmanim for Jerushalayim:
  {
    'hadlokas_haneiros': '2024-05-31T15:59:12.468117+00:00',
    'plag_hamincha': '2024-05-31T15:11:15.201081+00:00',
    'sunrise': '2024-05-31T02:34:50.704559+00:00',
    'sunset': '2024-05-31T16:39:12.468117+00:00',
    'tzeis_hakochavim': '2024-05-31T17:21:11.859783+00:00',
    'tzeis_minutes': '2024-05-31T17:51:12.468117+00:00'
  }

  Location(
    latitude=31.76904, longitude=35.21633,
    use_tzeis_hakochavim=True,
    hadlokas_haneiros_minutes=40,
    tzeis_minutes=72
  )


.. include_quickstart_end


Resources
---------

- `JewCal @ PyPI <https://pypi.org/project/jewcal/>`_
- `JewCal @ Read the Docs <https://jewcal.readthedocs.io/>`_
