Skip to main content

Versão beta da biblioteca de feriados municipais.

Project description

Brazil Municipal Holidays

A Python library to manage municipal holidays in the cities of Juiz de Fora, Coronel Fabriciano, Ipatinga and Governador Valadares. This library allows users to check, create, delete and manipulate holidays, including marking non-mandatory holidays as mandatory and vice versa.

Functionalities

  • Check holidays: Retrieve holidays for specific cities.
  • Create holidays: Add new holidays to the city's list of holidays.
  • Delete Holidays: Remove holidays from the city's holiday list.
  • Check optional holidays: Identify which holidays are optional.
  • Manipulate holidays: Change the status of holidays from non-mandatory to mandatory and vice versa.

Installation

You can install the library using pip: pip install feriados-municipios

How to use

Here are some examples to get you started:

Importing the Library from feriados_municipios import *

Initialize Variables

import feriados_municipios
from datetime import date

hoje = date.today()

feriados_municipios.FeriadosBrasil(hoje)
feriados_municipios.FeriadosBrasil.Ipatinga.init()

print(feriados_municipios.FeriadosBrasil.Ipatinga.get_feriados_regionais())

Add a New Holiday to the List for a Specified City

FeriadosBrasil.Ipatinga.new_feriado_personalizado(day=1, month=2, name="Example Holiday", facultativo=False)

Check if the Date and Holiday

FeriadosBrasil.Ipatinga.is_feriado()

Set a Holiday as Optional

FeriadosBrasil.Ipatinga.set_feriado_as_facultativo_by_date(20, 7)

Get Optional Holidays from a Municipality

FeriadosBrasil.Ipatinga.get_feriados_facultativos()

Remove a Holiday

FeriadosBrasil.Ipatinga.del_feriado_by_date(20, 7)

Contributions

We accept contributions! Please read our contributing guidelines for more information.

License

This project is licensed under the MIT License - see the LICENSE file for more details.

Feel free to modify this template to better suit the specifics and structure of your library.

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

feriados_municipios-0.0.1.tar.gz (7.1 kB view details)

Uploaded Source

Built Distribution

feriados_municipios-0.0.1-py3-none-any.whl (7.4 kB view details)

Uploaded Python 3

File details

Details for the file feriados_municipios-0.0.1.tar.gz.

File metadata

  • Download URL: feriados_municipios-0.0.1.tar.gz
  • Upload date:
  • Size: 7.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.6

File hashes

Hashes for feriados_municipios-0.0.1.tar.gz
Algorithm Hash digest
SHA256 9a3bf6e6ece75ef1220456d942b67261a5260a7d1f2e29f9fd92a4a3adf99c8b
MD5 16a8fa233968200a0403892d110819af
BLAKE2b-256 3c3e0cd4c3a954c4073daac1bafc63acc69995d27fc2dfa2142ef50aec9b3d77

See more details on using hashes here.

File details

Details for the file feriados_municipios-0.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for feriados_municipios-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 6feeec6fc2282cce98dbc4db98fb5311cec1ea21296c8fd009c5580fb585e42f
MD5 d7ed503eae94a219534102c6ce907129
BLAKE2b-256 fd3979fac57b9a2cc98fbc60cbb6d8ffca6fcf1436655ac1b2d315b5a0cec140

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page