File tree Expand file tree Collapse file tree 3 files changed +88
-59
lines changed
Expand file tree Collapse file tree 3 files changed +88
-59
lines changed Original file line number Diff line number Diff line change 1+ name : CLI PR checks
2+ description : check the CLI PR
3+
4+ on :
5+ pull_request :
6+ paths : ['cli/**']
7+
8+ concurrency :
9+ group : ${{ github.ref }}-cli-pr-checks
10+ cancel-in-progress : true
11+
12+ jobs :
13+ check-code :
14+ runs-on : ubuntu-latest
15+
16+ steps :
17+ - uses : actions/checkout@v4
18+
19+ - name : Setup Node.js
20+ uses : actions/setup-node@v4
21+ with :
22+ node-version : ' 20'
23+ cache : ' npm'
24+
25+ - name : Install dependencies
26+ working-directory : cli
27+ run : npm ci
28+
29+ - name : Build
30+ working-directory : cli
31+ run : npm run build
32+
33+ - name : Check format
34+ working-directory : cli
35+ run : npm run check-format
36+
37+ - name : Lint
38+ working-directory : cli
39+ run : npm run lint
40+
41+ - name : Test no crash
42+ working-directory : cli
43+ run : |
44+ npm i -g .
45+ iapp -h
46+
47+ npm-dry-run :
48+ uses : ./.github/workflows/reusable-cli-npm.yml
49+ with :
50+ dry-run : true
Original file line number Diff line number Diff line change 1+ name : npm publish
2+ description : reusable npm workflow for this project
3+
4+ on :
5+ workflow_call :
6+ inputs :
7+ dry-run :
8+ description : ' Run in dry-run mode (the package will not be published)'
9+ default : false
10+ type : boolean
11+ version :
12+ description :
13+ ' Version to publish (leave empty to use package.json version)'
14+ default : ' '
15+ type : string
16+ tag :
17+ description : ' npm publish tag (e.g., latest, nightly)'
18+ default : ' '
19+ type : string
20+ secrets :
21+ npm-token :
22+ description : ' NPM auth token (required unless `dry-run: true`)'
23+ required : false
24+
25+ jobs :
26+ npm-publish :
27+ uses :
iExecBlockchainComputing/github-actions-workflows/.github/workflows/[email protected] 28+ with :
29+ working-directory : cli
30+ install-command : npm ci
31+ build-command : npm run build
32+ dry-run : ${{ inputs.dry-run }}
33+ tag : ${{ inputs.tag }}
34+ version : ${{ inputs.version }}
35+ environment : ${{ (inputs.dry-run && '') || inputs.tag }}
36+ provenance : ${{ !inputs.dry-run }}
37+ secrets :
38+ npm-token : ${{ secrets.npm-token }}
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments