|
4 | 4 | workflow_call: |
5 | 5 | inputs: |
6 | 6 | scope: |
7 | | - description: 'NPM package scope (e.g., @iexec)' |
8 | | - default: '@iexec' |
| 7 | + description: "NPM package scope (e.g., @iexec)" |
| 8 | + default: "@iexec" |
9 | 9 | type: string |
10 | 10 | node-version: |
11 | | - description: 'Node.js version to use' |
12 | | - default: '20' |
| 11 | + description: "Node.js version to use" |
| 12 | + default: "20" |
13 | 13 | type: string |
14 | 14 | registry: |
15 | | - description: 'NPM registry URL' |
16 | | - default: 'https://registry.npmjs.org' |
| 15 | + description: "NPM registry URL" |
| 16 | + default: "https://registry.npmjs.org" |
17 | 17 | type: string |
18 | 18 | access: |
19 | | - description: 'Package access (public/restricted)' |
20 | | - default: 'public' |
| 19 | + description: "Package access (public/restricted)" |
| 20 | + default: "public" |
21 | 21 | type: string |
22 | 22 | provenance: |
23 | | - description: 'Enable npm provenance' |
| 23 | + description: "Enable npm provenance" |
24 | 24 | default: true |
25 | 25 | type: boolean |
26 | 26 | install-command: |
27 | | - description: 'Install dependencies command' |
28 | | - default: 'npm ci' |
| 27 | + description: "Install dependencies command" |
| 28 | + default: "npm ci" |
29 | 29 | type: string |
30 | 30 | build-command: |
31 | | - description: 'Build package command' |
32 | | - default: 'npm run build' |
| 31 | + description: "Build package command" |
| 32 | + default: "npm run build" |
33 | 33 | type: string |
34 | 34 | run-tests: |
35 | | - description: 'Execute unit tests step' |
| 35 | + description: "Execute unit tests step" |
36 | 36 | default: false |
37 | 37 | type: boolean |
38 | 38 | test-command: |
39 | | - description: 'Run unit tests command' |
40 | | - default: 'npm test --if-present' |
| 39 | + description: "Run unit tests command" |
| 40 | + default: "npm test --if-present" |
41 | 41 | type: string |
42 | 42 | lint-command: |
43 | | - description: 'Run linting command' |
44 | | - default: 'npm run lint --if-present' |
| 43 | + description: "Run linting command" |
| 44 | + default: "npm run lint --if-present" |
45 | 45 | type: string |
46 | 46 | type-check-command: |
47 | | - description: 'Run type-checking command' |
48 | | - default: 'npm run check-types --if-present' |
| 47 | + description: "Run type-checking command" |
| 48 | + default: "npm run check-types --if-present" |
49 | 49 | type: string |
50 | 50 | format-check-command: |
51 | | - description: 'Run format-checking command' |
52 | | - default: 'npm run check-format --if-present' |
| 51 | + description: "Run format-checking command" |
| 52 | + default: "npm run check-format --if-present" |
53 | 53 | type: string |
54 | 54 | environment: |
55 | | - description: 'GitHub environment' |
56 | | - default: 'production' |
| 55 | + description: "GitHub environment" |
| 56 | + default: "production" |
57 | 57 | type: string |
58 | 58 | tag: |
59 | | - description: 'npm publish tag (e.g., latest, nightly)' |
60 | | - default: '' |
| 59 | + description: "npm publish tag (e.g., latest, nightly)" |
| 60 | + default: "" |
61 | 61 | type: string |
62 | 62 | tag-prefix: |
63 | | - description: 'Prefix for Git tag' |
64 | | - default: 'v' |
| 63 | + description: "Prefix for Git tag" |
| 64 | + default: "v" |
65 | 65 | type: string |
66 | 66 | working-directory: |
67 | | - description: 'Directory containing package.json' |
68 | | - default: '' |
| 67 | + description: "Directory containing package.json" |
| 68 | + default: "" |
69 | 69 | type: string |
70 | 70 | artifact-name: |
71 | | - description: 'Name of an artifact to download before the build (leave empty to skip)' |
72 | | - default: '' |
| 71 | + description: "Name of an artifact to download before the build (leave empty to skip)" |
| 72 | + default: "" |
73 | 73 | type: string |
74 | 74 | artifact-path: |
75 | | - description: 'Destination path for the downloaded artifact' |
76 | | - default: '' |
| 75 | + description: "Destination path for the downloaded artifact" |
| 76 | + default: "" |
77 | 77 | type: string |
78 | 78 | version: |
79 | | - description: 'Version to publish (leave empty to use package.json version)' |
80 | | - default: '' |
| 79 | + description: "Version to publish (leave empty to use package.json version)" |
| 80 | + default: "" |
81 | 81 | type: string |
82 | 82 | dry-run: |
83 | | - description: 'Run in dry-run mode (the package will not be published)' |
| 83 | + description: "Run in dry-run mode (the package will not be published)" |
84 | 84 | default: false |
85 | 85 | type: boolean |
86 | 86 | secrets: |
87 | 87 | npm-token: |
88 | | - description: 'NPM auth token' |
| 88 | + description: "NPM auth token" |
89 | 89 | required: true |
90 | 90 |
|
91 | 91 | jobs: |
@@ -115,7 +115,7 @@ jobs: |
115 | 115 | - name: Install dependencies |
116 | 116 | working-directory: ${{ inputs.working-directory }} |
117 | 117 | run: ${{ inputs.install-command }} |
118 | | - |
| 118 | + |
119 | 119 | - name: Override version |
120 | 120 | if: ${{ inputs.version != '' }} |
121 | 121 | working-directory: ${{ inputs.working-directory }} |
|
0 commit comments