release-it插件的配置文件
module.exports = { git: { changelog: 'git log --pretty=format:"* %s (%h)"', commit: true, requireCleanWorkingDir: false, // 如果本地有文件变更而不需要提交则设为false requireCommits: false, commitMessage: 'Release v${version}', tag: true, tagName: 'v${version}', tagAnnotation: 'v${version}', push: true, requireUpstream: true, requireBranch: 'master' }, npm: { publish: false }, gitlab: { release: true, releaseName: 'v${version}', tokenRef: 'KFZ_GITLAB_TOKEN', assets: [] }, plugins: { '@release-it/keep-a-changelog': { 'filename': 'CHANGELOG.md' } } };
# 发布alpha $ release-it major --preRelease=alpha v1.0.0-alpha.0 # 发布beta $ release-it major --preRelease=beta v1.0.0-beta.0 # 发布rc $ release-it major --preRelease=rc v1.0.0-rc.0 # 继续上一版本迭代 release-it --preRelease # 发布正式版本 release-it major