{"id":23256798,"url":"https://github.com/dmdv/waitgrouptimeout","last_synced_at":"2025-04-06T04:25:28.500Z","repository":{"id":246803566,"uuid":"822996834","full_name":"Dmdv/WaitGroupTimeout","owner":"Dmdv","description":"WaitGroupTimeout","archived":false,"fork":false,"pushed_at":"2024-07-02T08:38:42.000Z","size":3,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-12T10:28:18.933Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","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/Dmdv.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2024-07-02T08:27:18.000Z","updated_at":"2024-07-02T08:38:07.000Z","dependencies_parsed_at":null,"dependency_job_id":"792b8c6f-62f5-4fee-b464-aff150c8926b","html_url":"https://github.com/Dmdv/WaitGroupTimeout","commit_stats":null,"previous_names":["dmdv/waitgrouptimeout"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dmdv%2FWaitGroupTimeout","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dmdv%2FWaitGroupTimeout/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dmdv%2FWaitGroupTimeout/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dmdv%2FWaitGroupTimeout/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Dmdv","download_url":"https://codeload.github.com/Dmdv/WaitGroupTimeout/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247432449,"owners_count":20938158,"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":[],"created_at":"2024-12-19T12:19:39.280Z","updated_at":"2025-04-06T04:25:28.093Z","avatar_url":"https://github.com/Dmdv.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# WaitGroupTimeout\n\nAn enhanced version of the built-in sync.WaitGroup of the Go,   \nwhich supports timeout processing and non-blocking status check\n\n```go\npackage main\n\nimport (\n\twgt \"github.com/dmdv/waitgrouptimeout\"\n\t\"time\"\n)\n\nfunc main() {\n\twg := wgt.New(true)\n\twg.Wrap(func() {\n\t\ttime.Sleep(5 * time.Second)\n\t\tprintln(\"Hello, world 1!\")\n\t})\n\n\twg.Wrap(func() {\n\t\ttime.Sleep(5 * time.Second)\n\t\tprintln(\"Hello, world 2!\")\n\t})\n\n\twg.Start()\n\twg.WaitTimeout(2 * time.Second)\n\tif wg.Finished() {\n\t\tprintln(\"Finished\")\n\t} else {\n\t\tprintln(\"Not finished\")\n\t}\n\n\tfor wg.Finished() != true {\n\t\ttime.Sleep(1 * time.Second)\n\t\tprintln(\"Waiting...\")\n\t}\n\twg.Wait()\n}\n\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdmdv%2Fwaitgrouptimeout","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdmdv%2Fwaitgrouptimeout","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdmdv%2Fwaitgrouptimeout/lists"}