@@ -16,7 +16,17 @@ const args = process.argv.slice(2).reduce((acc, a) => {
16
16
return acc
17
17
} , { } )
18
18
19
- const PUBLISH_STEPS = `
19
+ /* eslint-disable max-len */
20
+ const MANUAL_PUBLISH_STEPS = `
21
+ 1. Checkout the release branch and test
22
+
23
+ \`\`\`sh
24
+ gh pr checkout <PR-NUMBER> --force
25
+ npm ${ args . lockfile ? 'ci' : 'update' }
26
+ npm test
27
+ gh pr checks <PR-NUMBER> -R {NWO} --watch
28
+ \`\`\`
29
+
20
30
1. Publish workspaces
21
31
22
32
\`\`\`sh
@@ -28,38 +38,35 @@ const PUBLISH_STEPS = `
28
38
\`\`\`sh
29
39
npm publish <PUBLISH-FLAGS>
30
40
\`\`\`
31
- `
32
41
33
- /* eslint-disable max-len */
34
- const DEFAULT_RELEASE_PROCESS = `
35
- 1. Checkout the release branch and test
42
+ 1. Merge release PR
36
43
37
44
\`\`\`sh
38
- gh pr checkout <PR-NUMBER> --force
39
- npm ${ args . lockfile ? 'ci' : 'update' }
40
- npm test
41
- gh pr checks --watch
45
+ gh pr merge <PR-NUMBER> -R {NWO} --rebase
46
+ git checkout <BASE-BRANCH>
47
+ git fetch
48
+ git reset --hard origin/<BASE-BRANCH>
42
49
\`\`\`
50
+ `
43
51
44
- ${ ! args . publish ? PUBLISH_STEPS : '' }
45
-
46
- 1. Merge release PR ${ args . publish ? `:rotating_light: Merging this will auto publish :rotating_light:` : '' }
52
+ const AUTO_PUBLISH_STEPS = `
53
+ 1. Merge release PR :rotating_light: Merging this will auto publish :rotating_light:
47
54
48
55
\`\`\`sh
49
- gh pr merge --rebase
50
- git checkout <BASE-BRANCH>
51
- git fetch
52
- git reset --hard origin/<BASE-BRANCH>
56
+ gh pr merge <PR-NUMBER> -R {NWO} --rebase
53
57
\`\`\`
58
+ `
54
59
60
+ const DEFAULT_RELEASE_PROCESS = ( args . publish ? AUTO_PUBLISH_STEPS : MANUAL_PUBLISH_STEPS ) + `
55
61
1. Check For Release Tags
56
62
57
63
Release Please will run on the just pushed release commit and create GitHub releases and tags for each package.
58
64
59
65
\`\`\`
60
66
gh run watch \`gh run list -R {NWO} -w release -b <BASE-BRANCH> -L 1 --json databaseId -q ".[0].databaseId"\`
61
67
\`\`\`
62
- ` /* eslint-enable max-len */
68
+ `
69
+ /* eslint-enable max-len */
63
70
64
71
const getReleaseProcess = async ( { owner, repo } ) => {
65
72
const RELEASE_LIST_ITEM = / ^ \d + \. \s / gm
0 commit comments