mirror of
https://github.com/vuejs/vue-cli.git
synced 2026-05-04 19:10:01 -05:00
workflow: allow version number as commit message
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
const chalk = require('chalk')
|
||||
const chalk = require('chalk') // eslint-disable-line
|
||||
const msgPath = process.env.GIT_PARAMS
|
||||
const msg = require('fs').readFileSync(msgPath, 'utf-8').trim()
|
||||
|
||||
const commitRE = /^(revert: )?(feat|fix|docs|style|refactor|perf|test|workflow|ci|chore|types)(\(.+\))?: .{1,50}/
|
||||
const commitRE = /^(v\d+\.\d+\.\d+(-(alpha|beta|rc.\d+))?$)|((revert: )?(feat|fix|docs|style|refactor|perf|test|workflow|ci|chore|types)(\(.+\))?: .{1,50})/
|
||||
|
||||
if (!commitRE.test(msg)) {
|
||||
console.log()
|
||||
|
||||
Reference in New Issue
Block a user