{"id":21991943,"url":"https://github.com/elct9620/lunar_calendar","last_synced_at":"2025-10-17T14:54:15.914Z","repository":{"id":52294742,"uuid":"255607865","full_name":"elct9620/lunar_calendar","owner":"elct9620","description":"The Lunar Calendar","archived":false,"fork":false,"pushed_at":"2021-05-01T02:49:58.000Z","size":19,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-28T09:48:51.310Z","etag":null,"topics":["calculator","calendar","ruby"],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/elct9620.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-04-14T12:49:40.000Z","updated_at":"2021-05-01T02:49:50.000Z","dependencies_parsed_at":"2022-08-20T23:10:54.199Z","dependency_job_id":null,"html_url":"https://github.com/elct9620/lunar_calendar","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elct9620%2Flunar_calendar","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elct9620%2Flunar_calendar/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elct9620%2Flunar_calendar/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elct9620%2Flunar_calendar/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elct9620","download_url":"https://codeload.github.com/elct9620/lunar_calendar/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245052619,"owners_count":20553161,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["calculator","calendar","ruby"],"created_at":"2024-11-29T20:12:15.624Z","updated_at":"2025-10-17T14:54:15.842Z","avatar_url":"https://github.com/elct9620.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LunarCalendar\n\nConvert Solar Date to Lunar Date\n\n## Reference\n\n* Table data from [isee15/Lunar-Solar-Calendar-Converter](https://github.com/isee15/Lunar-Solar-Calendar-Converter)\n* Calculate discussion from [https://destiny.to/](https://destiny.to/ubbthreads/ubbthreads.php/ubb/showflat/Number/92769/site_id/1#import)\n\n## Data Structure\n\n### LunarCalendar::Data::NEW_YEARS\n\nEach value stores the Chinese New Year date in solar calendar\n\n| Name | Length\n|------|--------\n| Year | 12 bit\n| Month | 4 bit\n| Day  | 5 bit\n\n### LunarCalendar::Data::LEAP_MONTHS\n\nEach value stores the month days and leap month\n\n| Name | Length | Description\n|------|--------|--------------\n| Leap Month | 4 bit | `0` means this year no leap month\n| Months | 12 bit | `1` is 30 days and `0` is 29 days\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n```ruby\ngem 'lunar_calendar'\n```\n\nAnd then execute:\n\n    $ bundle install\n\nOr install it yourself as:\n\n    $ gem install lunar_calendar\n\n## Usage\n\n```ruby\nLunarCalendar.at_lunar(2020, 1, 1)\n# =\u003e #\u003cLunarCalendar::Lunar @year=2019 @month=12 @day=7\u003e\n```\n\n## Development\n\nAfter checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.\n\nTo install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at https://github.com/elct9620/lunar_calendar. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/elct9620/lunar_calendar/blob/master/CODE_OF_CONDUCT.md).\n\n\n## Code of Conduct\n\nEveryone interacting in the LunarCalendar project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/elct9620/lunar_calendar/blob/master/CODE_OF_CONDUCT.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felct9620%2Flunar_calendar","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felct9620%2Flunar_calendar","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felct9620%2Flunar_calendar/lists"}