Skip to content
This repository has been archived by the owner on May 11, 2021. It is now read-only.

Commit

Permalink
chore: 用shell脚本自动发版
Browse files Browse the repository at this point in the history
  • Loading branch information
dream2023 committed Feb 10, 2020
1 parent 5efba46 commit f8297cd
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 6 deletions.
8 changes: 4 additions & 4 deletions .grenrc.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module.exports = {
dataSource: 'commits',
includeMessages: 'commits',
ignoreCommitsWith: ['changelog', 'release'],
changelogFilename: 'CHANGELOG.md'
dataSource: 'commits',
includeMessages: 'commits',
ignoreCommitsWith: ['changelog', 'release'],
changelogFilename: 'CHANGELOG.md'
}
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@
"serve": "vue-cli-service serve",
"build": "vue-cli-service build",
"lint": "vue-cli-service lint --mode production",
"release": "standard-version",
"pubs": "npm run build && npm run release && npm publish --registry http://registry.npmjs.org && git push --follow-tags origin master && gren release --override"
"release": "./release.sh"
},
"bin": {
"fgen": "./bin/fgen"
Expand Down
10 changes: 10 additions & 0 deletions release.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/bash
npm run lint
npm run build
npm run release
npm publish --registry http://registry.npmjs.org
git push
git checkout master
git merge develop
git push --follow-tags origin master
npx gren release --override
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@ export default {
return Promise.resolve()
},
handleRequestSuccess(data) {
// eslint-disable-next-line no-console
console.log('data')
this.$message.success('发送成功')
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ export default {
},
methods: {
handleRequest(data) {
// eslint-disable-next-line no-console
console.log(data)
return Promise.resolve(data)
},
Expand Down
2 changes: 2 additions & 0 deletions start.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ function updateCheck () {
if (notifier.update) {
message.push('Update available: ' + chalk.green.bold(notifier.update.latest) + chalk.gray(' (current: ' + notifier.update.current + ');'))
message.push('Run ' + chalk.magenta('npm install -g ' + pkg.name) + ' Or ' + chalk.magenta('yarn global add ' + pkg.name) + ' to update.')
// eslint-disable-next-line no-console
console.log(message.join('\r\n'))
}
}
Expand Down Expand Up @@ -49,6 +50,7 @@ program
program.parse(process.argv)

server.listen(program.port, () => {
// eslint-disable-next-line no-console
console.log(`Running at http://localhost:${program.port}`)
openURL(`http://localhost:${program.port}`)
})

0 comments on commit f8297cd

Please sign in to comment.