Skip to content

Commit aeef37d

Browse files
committed
chore(workflows): refactor github workflows for new npm auth
1 parent a9d1b7e commit aeef37d

4 files changed

Lines changed: 42 additions & 19 deletions

File tree

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
name: 'Ionicons Dev Build'
1+
name: 'Dev Release'
22

33
on:
4-
workflow_dispatch:
4+
workflow_call:
55

66
jobs:
77
create-dev-hash:
Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,12 @@
1-
name: 'Ionicons Production Release'
1+
name: 'Production Release'
22

33
on:
4-
workflow_dispatch:
4+
workflow_call:
55
inputs:
66
version:
7-
required: true
8-
type: choice
9-
description: Which version should be published?
10-
options:
11-
- patch
12-
- minor
13-
- major
14-
tag:
15-
required: true
16-
type: choice
17-
description: Which npm tag should this be published to?
18-
options:
19-
- latest
7+
required: false
8+
type: string
9+
description: npm version (major, minor, or patch)
2010

2111
jobs:
2212
release-ionicons:
@@ -31,7 +21,7 @@ jobs:
3121
- name: Publish to NPM
3222
uses: ./.github/workflows/actions/publish-npm
3323
with:
34-
tag: ${{ inputs.tag }}
24+
tag: latest
3525
version: ${{ inputs.version }}
3626
working-directory: './'
3727
token: ${{ secrets.NPM_TOKEN }}
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: 'Release Orchestrator'
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
release-type:
7+
description: 'Release type'
8+
required: true
9+
type: choice
10+
options:
11+
- dev
12+
- production
13+
version:
14+
description: 'Version for production releases'
15+
required: false
16+
type: choice
17+
options:
18+
- patch
19+
- minor
20+
- major
21+
22+
jobs:
23+
run-dev:
24+
if: ${{ inputs.release-type == 'dev' }}
25+
uses: ./.github/workflows/dev-release.yml
26+
secrets: inherit
27+
28+
run-production:
29+
if: ${{ inputs.release-type == 'production' }}
30+
uses: ./.github/workflows/production-release.yml
31+
secrets: inherit
32+
with:
33+
version: ${{ inputs.version }}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: 'Ionicons Build'
1+
name: 'Validation'
22

33
on:
44
pull_request:

0 commit comments

Comments
 (0)