{"id":13412469,"url":"https://github.com/nathan-osman/go-sunrise","last_synced_at":"2025-04-05T23:09:56.099Z","repository":{"id":50125978,"uuid":"94477788","full_name":"nathan-osman/go-sunrise","owner":"nathan-osman","description":"Go package for calculating the sunrise and sunset times for a given location","archived":false,"fork":false,"pushed_at":"2024-04-23T10:07:48.000Z","size":61,"stargazers_count":142,"open_issues_count":4,"forks_count":17,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-07-31T20:50:57.564Z","etag":null,"topics":["astronomy","calendar","golang","sunrise","sunset"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nathan-osman.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-06-15T20:49:41.000Z","updated_at":"2024-07-29T06:47:25.000Z","dependencies_parsed_at":"2024-06-18T15:15:01.752Z","dependency_job_id":"f160d495-e5b6-4ea0-a519-b2df9502a7da","html_url":"https://github.com/nathan-osman/go-sunrise","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nathan-osman%2Fgo-sunrise","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nathan-osman%2Fgo-sunrise/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nathan-osman%2Fgo-sunrise/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nathan-osman%2Fgo-sunrise/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nathan-osman","download_url":"https://codeload.github.com/nathan-osman/go-sunrise/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247411235,"owners_count":20934653,"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":["astronomy","calendar","golang","sunrise","sunset"],"created_at":"2024-07-30T20:01:25.027Z","updated_at":"2025-04-05T23:09:56.074Z","avatar_url":"https://github.com/nathan-osman.png","language":"Go","funding_links":[],"categories":["Date and Time","日期和时间","日期和时间`用于处理日期和时间的库`","\u003cspan id=\"日期和时间-date-and-time\"\u003e日期和时间 Date and Time\u003c/span\u003e","Relational Databases"],"sub_categories":["Advanced Console UIs","Search and Analytic Databases","检索及分析资料库","SQL 查询语句构建库","\u003cspan id=\"高级控制台用户界面-advanced-console-uis\"\u003e高级控制台用户界面 Advanced Console UIs\u003c/span\u003e"],"readme":"## go-sunrise\n\n[![Build Status](https://app.travis-ci.com/nathan-osman/go-sunrise.svg?branch=master)](https://app.travis-ci.com/nathan-osman/go-sunrise)\n[![Coverage Status](https://coveralls.io/repos/github/nathan-osman/go-sunrise/badge.svg?branch=master)](https://coveralls.io/github/nathan-osman/go-sunrise?branch=master)\n[![Go Report Card](https://goreportcard.com/badge/github.com/nathan-osman/go-sunrise)](https://goreportcard.com/report/github.com/nathan-osman/go-sunrise)\n[![GoDoc](https://godoc.org/github.com/nathan-osman/go-sunrise?status.svg)](https://godoc.org/github.com/nathan-osman/go-sunrise)\n[![MIT License](http://img.shields.io/badge/license-MIT-9370d8.svg?style=flat)](http://opensource.org/licenses/MIT)\n\nGo package for calculating the sunrise and sunset times for a given location based on [this method](https://en.wikipedia.org/wiki/Sunrise_equation#Complete_calculation_on_Earth).\n\n### Usage\n\nTo calculate sunrise and sunset times, you will need the following information:\n\n- the date for which you wish to calculate the times\n- the latitude and longitudinal coordinates of the location\n\nBegin by importing the package:\n\n    import \"github.com/nathan-osman/go-sunrise\"\n\nNext, feed the information into the SunriseSunset() method:\n\n    rise, set := sunrise.SunriseSunset(\n        43.65, -79.38,          // Toronto, CA\n        2000, time.January, 1,  // 2000-01-01\n    )\n\nThe two return values will be the sunrise and sunset times for the location on the given day as time.Time values. If sun does not rise or set, both return values will be time.Time{}.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnathan-osman%2Fgo-sunrise","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnathan-osman%2Fgo-sunrise","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnathan-osman%2Fgo-sunrise/lists"}