提交 ba90b6ed 编写于 作者: M meteorlxy

build: cleanup changelog in release script

上级 430b9177
......@@ -29,6 +29,7 @@
process.env.VUE_CLI_RELEASE = true
const fs = require('fs')
const execa = require('execa')
const semver = require('semver')
const inquirer = require('inquirer')
......@@ -114,6 +115,17 @@ const release = async () => {
await execa(require.resolve('lerna/cli'), releaseArguments, { stdio: 'inherit' })
await execa('yarn', ['changelog'])
// cleanup changelog
fs.writeFileSync(
'CHANGELOG.md',
fs.readFileSync('CHANGELOG.md')
.toString()
.split('\n')
.slice(4)
.join('\n')
)
await execa('git', ['add', '-A'], { stdio: 'inherit' })
await execa('git', ['commit', '-m', `chore: ${version} changelog`], { stdio: 'inherit' })
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册