GithubHelp home page GithubHelp logo

mokejp / holidays_jp Goto Github PK

View Code? Open in Web Editor NEW
14.0 2.0 3.0 16 KB

日本の祝日 祝祭日 を計算するPythonライブラリ

License: MIT License

Python 100.00%
python holiday holidays holiday-calculation holiday-japan

holidays_jp's Introduction

holidays-jp: Japanese holidays

https://travis-ci.org/mokejp/holidays_jp.svg?branch=master

holidays-jp is a library for calculate holidays. Mainly it has been optimized to Japanese.

It can be used in standalone and does not depend on Google calendar.

Usage:

from holidays_jp import CountryHolidays
# get japanese holidays in 2015.
holidays = CountryHolidays.get('JP', 2015)
# [
#     (datetime.datetime(2015, 1, 1, 0, 0), '元日'),
#     (datetime.datetime(2015, 1, 12, 0, 0), '成人の日'),
#     (datetime.datetime(2015, 2, 11, 0, 0), '建国記念の日'),
#     (datetime.datetime(2015, 3, 21, 0, 0), '春分の日'),
#     (datetime.datetime(2015, 4, 29, 0, 0), '昭和の日'),
#     (datetime.datetime(2015, 5, 3, 0, 0), '憲法記念日'),
#     (datetime.datetime(2015, 5, 4, 0, 0), 'みどりの日'),
#     (datetime.datetime(2015, 5, 5, 0, 0), 'こどもの日'),
#     (datetime.datetime(2015, 5, 6, 0, 0), '振替休日'),
#     (datetime.datetime(2015, 7, 20, 0, 0), '海の日'),
#     (datetime.datetime(2015, 9, 21, 0, 0), '敬老の日'),
#     (datetime.datetime(2015, 9, 22, 0, 0), '国民の休日'),
#     (datetime.datetime(2015, 9, 23, 0, 0), '秋分の日'),
#     (datetime.datetime(2015, 10, 12, 0, 0), '体育の日'),
#     (datetime.datetime(2015, 11, 3, 0, 0), '文化の日'),
#     (datetime.datetime(2015, 11, 23, 0, 0), '勤労感謝の日'),
#     (datetime.datetime(2015, 12, 23, 0, 0), '天皇誕生日')
# ]

# get japanese holidays in 2015-2016.
holidays = CountryHolidays.between('JP', 2015, 2016)

# get USA holidays in 2015
holidays = CountryHolidays.get('US', 2015)

holidays_jp's People

Contributors

glebberjoskin avatar mokejp avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

natsuapo knok

holidays_jp's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.