{"id":19666126,"url":"https://github.com/aboehm/tsenum","last_synced_at":"2025-02-27T04:16:04.110Z","repository":{"id":62585429,"uuid":"60405793","full_name":"aboehm/tsenum","owner":"aboehm","description":"Timestamp enumerator","archived":false,"fork":false,"pushed_at":"2023-09-26T15:10:54.000Z","size":39,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-10-16T09:13:02.041Z","etag":null,"topics":["enumerator","python","timestamps","tool"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aboehm.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":"2016-06-04T10:48:59.000Z","updated_at":"2023-09-26T14:34:59.000Z","dependencies_parsed_at":"2024-11-11T16:38:18.941Z","dependency_job_id":null,"html_url":"https://github.com/aboehm/tsenum","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aboehm%2Ftsenum","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aboehm%2Ftsenum/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aboehm%2Ftsenum/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aboehm%2Ftsenum/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aboehm","download_url":"https://codeload.github.com/aboehm/tsenum/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240976196,"owners_count":19887439,"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":["enumerator","python","timestamps","tool"],"created_at":"2024-11-11T16:26:22.364Z","updated_at":"2025-02-27T04:16:04.091Z","avatar_url":"https://github.com/aboehm.png","language":"Python","readme":"# tsenum\n\n[![Tests](https://github.com/aboehm/tsenum/actions/workflows/tests.yml/badge.svg)](https://github.com/aboehm/tsenum/actions/workflows/tests.yml)\n\nA timestamp generator.\n\n## Install\n\nYou can use pip to install from the repository\n\n```\npip install tsenum\n```\n\nor download sources and run pip from this directory\n\n```\ngit clone https://github.com/aboehm/tsenum\npip install .\n```\n\n## Usage\n\n`tsenum` provides an CLI. For help run:\n\n```\ntsenum -h\n```\n\nTo count 7 days back from yesterday via CLI, run:\n\n```sh\ntsenum --offset -1 --count -7 --step day --pattern \"%Y-%m-%d: Hello world!\"\n2016-05-27: Hello world!\n2016-05-28: Hello world!\n2016-05-29: Hello world!\n2016-05-30: Hello world!\n2016-05-31: Hello world!\n2016-06-01: Hello world!\n2016-06-02: Hello world!\n```\n\nTo do it programmatically:\n\n```python\nfrom datetime import datetime\nimport tsenum\n\nprint(\n    tsenum.enumerate_times(\n        datetime.now().astimezone(),\n        offset=-1,\n        count=-7,\n        step=tsenum.Step.DAY,\n        pattern='%Y-%m-%d'\n    )\n)\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faboehm%2Ftsenum","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faboehm%2Ftsenum","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faboehm%2Ftsenum/lists"}