File tree Expand file tree Collapse file tree 1 file changed +46
-0
lines changed Expand file tree Collapse file tree 1 file changed +46
-0
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ on :
3
+ workflow_dispatch :
4
+ inputs :
5
+ ref :
6
+ description : ' Enter a full Git SHA to create a prerelease for'
7
+ required : true
8
+
9
+ name : Publish a pre-release version of the CLI from a SHA
10
+
11
+ jobs :
12
+ prerelease :
13
+ runs-on : ubuntu-latest
14
+ permissions :
15
+ id-token : write
16
+ contents : write
17
+ steps :
18
+ - name : Check out specified ref (${{ inputs.ref }})
19
+ uses : actions/checkout@v4
20
+ with :
21
+ ref : ${{ inputs.ref }}
22
+
23
+ - uses : actions/setup-node@v4
24
+ with :
25
+ node-version : ' 18.17.0'
26
+ cache : npm
27
+ registry-url : ' https://registry.npmjs.org'
28
+
29
+ - name : Install core dependencies
30
+ run : npm ci --no-audit
31
+
32
+ - name : Build
33
+ run : npm run build
34
+
35
+ - name : Configure Git user
36
+ run : |
37
+ git config --global user.name "Netlify"
38
+ git config --global user.email "82042599+token-generator-app[bot]@users.noreply.github.com"
39
+
40
+ - name : Run npm version
41
+ run : npm --no-git-tag-version version "\$(jq --raw-output .version package.json)-pre.\$(git rev-parse --short ${{ inputs.ref }})"
42
+
43
+ - name : Run npm publish
44
+ run : npm publish --provenance
45
+ env :
46
+ NODE_AUTH_TOKEN : ${{secrets.NPM_TOKEN}}
You can’t perform that action at this time.
0 commit comments