{"id":24571766,"url":"https://github.com/dncrews/date-tag","last_synced_at":"2025-04-23T02:45:41.748Z","repository":{"id":57211542,"uuid":"445000097","full_name":"dncrews/date-tag","owner":"dncrews","description":"Create git tags that are date based and versioned for that date. e.g. v2022-01-01.1","archived":false,"fork":false,"pushed_at":"2022-01-06T21:03:18.000Z","size":40,"stargazers_count":1,"open_issues_count":0,"forks_count":3,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-23T02:45:35.512Z","etag":null,"topics":["git","npm-package","tagging"],"latest_commit_sha":null,"homepage":"https://npmjs.com/package/date-tag","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"wtfpl","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dncrews.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-01-06T01:17:36.000Z","updated_at":"2023-08-01T20:04:18.000Z","dependencies_parsed_at":"2022-08-30T12:30:19.356Z","dependency_job_id":null,"html_url":"https://github.com/dncrews/date-tag","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dncrews%2Fdate-tag","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dncrews%2Fdate-tag/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dncrews%2Fdate-tag/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dncrews%2Fdate-tag/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dncrews","download_url":"https://codeload.github.com/dncrews/date-tag/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250360251,"owners_count":21417717,"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":["git","npm-package","tagging"],"created_at":"2025-01-23T18:38:13.438Z","updated_at":"2025-04-23T02:45:41.726Z","avatar_url":"https://github.com/dncrews.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# date-tag\n\n[\u003cimg\n  src=\"http://www.wtfpl.net/wp-content/uploads/2012/12/wtfpl-badge-4.png\"\n  width=\"80\" height=\"15\" alt=\"WTFPL\" /\u003e](http://www.wtfpl.net/\")\n\nThe goal of this package is to create (and push) git tags that are date based. This is sometimes used to push applications that aren't \"versioned\" in the semver sense, but have date-based deployments.\n\n**Note: these tags are annotated tags. See the \"Creating Tags\" section of the [Tagging docs.](https://git-scm.com/book/en/v2/Git-Basics-Tagging)**\n\n\n## Tag Format\n\nThe git tag that is created will come in the format of:\n`\u003cprefix\u003e\u003cYYYY\u003e-\u003cMM\u003e-\u003cDD\u003e.\u003cversion\u003e`\n\n- Prefix\n  - Denotes whether it was a full release or a release candidate\n- YYYY\n  - 4-digit calendar year\n- MM\n  - 2-digit calendar month\n- DD\n  - 2-digit calendar day\n- Version\n  - Denotes which deployment this is for today.\n    - `.1` would be the first deployment with that prefix\n    - `.10` would be the tenth.\n\n### Examples\n\n| Example | Command | Prefix | YYYY | MM | DD | Version |\n| --: | -- | -- | -- | -- | -- | -- |\n| rc-v2022-01-06.15 | `date-tag rc` | `rc-v` | `2022` | `01` | `06` | `15` |\n| v2022-10-20.2 | `date-tag prod` | `v` | `2022` | `10` | `20` | `2` |\n\n\n## Usage\n\n### Without installation\nThe easiest way to use this package is simply to use `npx` to call it. You do not need to install it first.\n```bash\n$ npx date-tag \u003crc | prod | push\u003e\n```\n\n### With installation\n\nFirst install it in your project with either:\n\n```bash\nnpm install -D date-tag\n```\n```bash\nyarn install -D date-tag\n```\n\nYou can then use the same npx command\n```bash\nnpx date-tag \u003crc | prod | push\u003e\n```\n\nOr you can add it to your package.json\n```json\n{\n  \"scripts\": {\n    \"release\": \"yarn run date-tag\"\n  }\n}\n```\nand then you can use\n```bash\nyarn release \u003crc | prod | push\u003e\n```\n\n### Options\nThere is only one option with multiple possible values:\n| Option | Purpose | Variations |\n| ----: | ---- |---- |\n| `rc` | Publishes a tag with the prefix `rc-v`\u003cbr /\u003ee.g. `rc-v2022-01-01.1` | `date-tag rc`\u003cbr /\u003e`date-tag beta`\u003cbr /\u003e`date-tag demo` |\n| `prod` | Publishes a tag with the prefix `v`\u003cbr /\u003ee.g. `v2022-01-01.1` | `date-tag prod`\u003cbr /\u003e`date-tag full`\u003cbr /\u003e`date-tag release` |\n| `push` | Shows you the tags for today and allows you to choose one to push to Github. (See Note below). | `date-tag push` |\n\n### Note on `push`\n\nThe reason the command `push` exists when `git push --tags` also exists is that I was personally frustrated when I had OTHER tags that shouldn't be pushed. For example, if I tagged a release yesterday that was never deployed, I don't want to push that one. The equivalent git command to push only the one tag would be:\n\n```bash\ngit push origin \"refs/tags/v2022-01-01.1\"\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdncrews%2Fdate-tag","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdncrews%2Fdate-tag","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdncrews%2Fdate-tag/lists"}