{"id":18823012,"url":"https://github.com/tomjs/release-cli","last_synced_at":"2026-03-16T11:13:03.341Z","repository":{"id":239777791,"uuid":"780729759","full_name":"tomjs/release-cli","owner":"tomjs","description":"A CLI tool to automatically publish npm packages.","archived":false,"fork":false,"pushed_at":"2024-05-22T11:59:33.000Z","size":526,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2024-05-22T12:56:27.373Z","etag":null,"topics":["cli","npm","publish","release"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/tomjs.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2024-04-02T03:42:47.000Z","updated_at":"2024-05-28T19:55:45.982Z","dependencies_parsed_at":"2024-05-22T13:04:30.424Z","dependency_job_id":null,"html_url":"https://github.com/tomjs/release-cli","commit_stats":null,"previous_names":["tomjs/release-cli"],"tags_count":15,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomjs%2Frelease-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomjs%2Frelease-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomjs%2Frelease-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomjs%2Frelease-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tomjs","download_url":"https://codeload.github.com/tomjs/release-cli/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244516001,"owners_count":20464991,"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":["cli","npm","publish","release"],"created_at":"2024-11-08T00:52:23.194Z","updated_at":"2025-12-27T09:47:08.391Z","avatar_url":"https://github.com/tomjs.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @tomjs/release-cli\n\n[![npm](https://img.shields.io/npm/v/@tomjs/release-cli)](https://www.npmjs.com/package/@tomjs/release-cli) ![node-current (scoped)](https://img.shields.io/node/v/@tomjs/release-cli) ![NPM](https://img.shields.io/npm/l/@tomjs/release-cli)\n\n**English** | [中文](./README.zh_CN.md)\n\n\u003e A `CLI` tool to automatically publish `npm` packages.\n\n## Notice\n\n- This tool learns and refers to the excellent [np](https://github.com/sindresorhus/np) and [changesets](https://github.com/changesets/changesets)\n- This tool is only used for learning and communication. It is not recommended for others to use for important projects. It is recommended to use the above tools\n\n## Features\n\n- You can select or customize the `npm` version number and `dist-tag`\n- Automatically generate `changelog` based on `git` information\n- Automatically publish to `https://registry.npmjs.org`\n- Create github release link\n\n## Prerequisite\n\n| name     | version |\n| -------- | ------- |\n| **node** | \u003e= 18   |\n| **git**  | \u003e= 2.11 |\n| npm      | \u003e= 7    |\n| pnpm     | \u003e= 8    |\n\n## Install\n\n```bash\n# pnpm\npnpm add @tomjs/release-cli -D\n\n# yarn\nyarn add @tomjs/release-cli -D\n\n# npm\nnpm add @tomjs/release-cli -D\n```\n\n## Usage\n\n```bash\n$ rc -h\n\nA CLI tool to automatically publish npm packages.\n\nUsage\n  $ rc [type] [options]\n\n  Type can be:\n    patch | minor | major | prepatch | preminor | premajor | prerelease\n\nOptions\n  --cwd                 The current working directory (default: \".\")\n  --config              Specify the config file path (eg. rc.config.json)\n  --preid               Specify the pre-release identifier, allowed values are \"\", \"alpha\", \"beta\", \"rc\".\n                        If type is \"prerelease\", \"prepatch\", \"preminor\", \"premajor\",\n                        the preid will be used as the pre-release identifier (default: \"alpha\").\n                        If type is \"patch\", \"minor\", \"major\", the preid will be ignored.\n  --no-git-check        Skips checking git status\n  --any-branch          Allow publishing from any branch (default: false)\n  --branch              Name of the release branch (default: main | master)\n  --tag \u003ctag\u003e           Publish under a given dist-tag (default: \"latest\")\n  --scoped-tag          Use scoped package name as git tag\n  --line-tag            Replace the '-' in the package name with '/' as git tag (eg. tomjs-release-cli-v1.0.0)\n  --no-log              Skips generating changelog\n  --log-full            Generate a full changelog and replace the existing content, not recommended (default: false)\n  --no-log-commit       Don't add git commit SHA and link to the changelog\n  --no-log-compare      Don't add git compare link to the changelog\n  --git-url             Specify the git web url. If not specified, the configuration of git or package.json will be read,\n                        such as \"https://github.com/tomjs/release-cli\"\n  --git-commit-url      Git commit url template, default: \"{url}/commit/{sha}\"\n  --git-compare-url     Git compare url template, default: \"{url}/compare/{diff}\"\n  --strict              Strict mode, will make some checks more strict (default: false)\n  --no-publish          Skips publishing\n  --build               Run build script before publishing (You can also use \"prepublishOnly\")\n  --no-tag-merge        When publishing multiple packages, each package has its own independent tag and commit\n  --otp                 This is a one-time password from a two-factor authenticator\n  --no-release-draft    Skips opening a GitHub release draft\n  --dry-run             Don't actually release, just simulate the process\n  --verbose             Display verbose output\n  -h, --help            Display this message\n  -v, --version         Display version number\n```\n\n## Configuration File\n\nYou can configure `release-cli` via (in order of precedence):\n\n- A \"`rc`\" key in your `package.json` file.\n- A `rc.config.json` file.\n- A `rc.config.js` file that exports an object using `export default` or `module.exports` (depends on the type value in your package.json).\n- A `rc.config.mjs` file that exports an object using export default.\n- A `rc.config.cjs` file that exports an object using module.exports.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftomjs%2Frelease-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftomjs%2Frelease-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftomjs%2Frelease-cli/lists"}