{"id":25902649,"url":"https://github.com/jonathanhecl/gotimeleft","last_synced_at":"2025-03-03T03:17:05.449Z","repository":{"id":61622992,"uuid":"533812590","full_name":"jonathanhecl/gotimeleft","owner":"jonathanhecl","description":"It is used to know how much estimated time is left to finish a task.","archived":false,"fork":false,"pushed_at":"2022-12-23T03:56:32.000Z","size":33,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2023-07-26T15:15:17.190Z","etag":null,"topics":["golang","left","time","timeleft"],"latest_commit_sha":null,"homepage":"","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/jonathanhecl.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-09-07T14:53:05.000Z","updated_at":"2023-02-08T08:48:02.000Z","dependencies_parsed_at":"2023-01-30T17:46:06.639Z","dependency_job_id":null,"html_url":"https://github.com/jonathanhecl/gotimeleft","commit_stats":null,"previous_names":[],"tags_count":0,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jonathanhecl%2Fgotimeleft","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jonathanhecl%2Fgotimeleft/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jonathanhecl%2Fgotimeleft/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jonathanhecl%2Fgotimeleft/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jonathanhecl","download_url":"https://codeload.github.com/jonathanhecl/gotimeleft/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241600473,"owners_count":19988715,"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":["golang","left","time","timeleft"],"created_at":"2025-03-03T03:17:04.948Z","updated_at":"2025-03-03T03:17:05.440Z","avatar_url":"https://github.com/jonathanhecl.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GoTimeLeft\n[![Go](https://github.com/jonathanhecl/gotimeleft/actions/workflows/go.yml/badge.svg)](https://github.com/jonathanhecl/gotimeleft/actions/workflows/go.yml)\n[![Go Report Card](https://goreportcard.com/badge/github.com/jonathanhecl/gotimeleft)](https://goreportcard.com/report/github.com/jonathanhecl/gotimeleft)\n[![License](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE)\n\n\u003e It is used to know how much estimated time is left to finish a task.\n\u003e \n\u003e Works like a progress bar too.\n\n## Example: \n\n![Image](https://i.imgur.com/MhitUfV.png)\n![Image](https://i.imgur.com/mKIGzX5.png)\n![Image](https://i.imgur.com/2vVI9qM.png)\n\n## How to install\n\n\u003e go get github.com/jonathanhecl/gotimeleft\n\n## How to use\n\n```\n  timeleft := gotimeleft.Init(100) // Total 100, value 0\n  \n  ...\n\n  timeleft.Reset(200) // Reset to total 200, value 0\n\n  ...\n\n  timeleft.Step(10) // value +10\n\n  ...\n\n  timeleft.Value(50) // value 50\n  \n  ...\n  \n  timeleft.GetProgressValues() // =\u003e 55/100 string\n  timeleft.GetProgress(2) // =\u003e 55.33% string with 2 decimals\n  timeleft.GetProgressBar(30) // [==============\u003e...............] string with 30 chars\n  timeleft.GetFloat64() // =\u003e 0.55 float64\n  timeleft.GetPerSecond() // =\u003e 5.55 float64 per second\n  timeleft.GetTimeLeft() // =\u003e 0.5ms time.Duration\n  timeleft.GetTimeSpent() // =\u003e 2s time.Duration\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjonathanhecl%2Fgotimeleft","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjonathanhecl%2Fgotimeleft","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjonathanhecl%2Fgotimeleft/lists"}