{"id":18702260,"url":"https://github.com/johnberroa/codetimer","last_synced_at":"2025-11-09T01:30:27.560Z","repository":{"id":132366498,"uuid":"164337748","full_name":"johnberroa/CodeTimer","owner":"johnberroa","description":null,"archived":false,"fork":false,"pushed_at":"2019-01-06T19:41:28.000Z","size":4,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2024-12-28T05:43:02.897Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","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/johnberroa.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-01-06T19:17:31.000Z","updated_at":"2019-01-06T19:37:05.000Z","dependencies_parsed_at":null,"dependency_job_id":"c04ff040-6594-46c5-a50b-b188408265ba","html_url":"https://github.com/johnberroa/CodeTimer","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnberroa%2FCodeTimer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnberroa%2FCodeTimer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnberroa%2FCodeTimer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnberroa%2FCodeTimer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/johnberroa","download_url":"https://codeload.github.com/johnberroa/CodeTimer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239565644,"owners_count":19660154,"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-11-07T11:45:20.198Z","updated_at":"2025-11-09T01:30:27.523Z","avatar_url":"https://github.com/johnberroa.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Code Timer\nThis lightweight timer can time any section of code desired, and makes converting run times to minutes/hours a lot easier than having to fiddle with your ```time.time() - start_time``` output.\n\n## Usage\nPrinting the timer while running or when stopped will return the current run time in seconds, minutes, and hours.\n```\ntimer = Timer(\"Repeating Calculation\")\ntimer.start()\nfor i in range(2):\n    function.apply()\n    print(timer)\ntimer.stop()\nprint(timer)\n```\nOutput will be:\n```\nTimer 'Repeating Calculation' still running: Time elapsed 'Repeating Calculation': 6s (.1m | 0h)\nTimer 'Repeating Calculation' still running: Time elapsed 'Repeating Calculation': 12s (.2m | 0h)\nTime elapsed 'Repeating Calculation': 7s (.1m | 0h)\n```\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnberroa%2Fcodetimer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjohnberroa%2Fcodetimer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnberroa%2Fcodetimer/lists"}