We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 935d235 commit 02fe0d9Copy full SHA for 02fe0d9
scripts/backport.js
@@ -4,6 +4,10 @@ const yargs = require(`yargs`)
4
const { Octokit } = require(`@octokit/rest`)
5
const childProcess = require(`child_process`)
6
7
+yargs.parserConfiguration({
8
+ "parse-numbers": false,
9
+})
10
+
11
if (!process.env.GITHUB_ACCESS_TOKEN) {
12
throw new Error(`GITHUB_ACCESS_TOKEN env var not set`)
13
}
@@ -22,7 +26,7 @@ const argv = yargs
22
26
.positional(`pr`, { type: `number` })
23
27
)
24
28
.check(argv => {
25
- if (!/^3\.\d+$/.test(argv.release)) {
29
+ if (!/^[1-9][0-9]*\.\d+$/.test(argv.release)) {
30
throw new Error(`"${argv.release}" is not a release version`)
31
32
0 commit comments