chore(ci): integrate preid with release flow

This commit is contained in:
Liam DeBeasi
2023-01-25 15:03:51 +00:00
parent 938ef0885d
commit 7a0650b1a2
3 changed files with 15 additions and 1 deletions

View File

@ -7,6 +7,8 @@ inputs:
description: 'The type of version to release.' description: 'The type of version to release.'
tag: tag:
description: 'The tag to publish to on NPM.' description: 'The tag to publish to on NPM.'
preid:
description: 'The prerelease identifier used when doing a prerelease.'
working-directory: working-directory:
description: 'The directory of the package.' description: 'The directory of the package.'
folder: folder:
@ -25,7 +27,7 @@ runs:
shell: bash shell: bash
working-directory: ${{ inputs.working-directory }} working-directory: ${{ inputs.working-directory }}
- name: Update Version - name: Update Version
run: lerna version ${{ inputs.version }} --yes --exact --no-changelog --no-push --no-git-tag-version run: lerna version ${{ inputs.version }} --yes --exact --no-changelog --no-push --no-git-tag-version --preid=${{ inputs.preid }}
shell: bash shell: bash
working-directory: ${{ inputs.working-directory }} working-directory: ${{ inputs.working-directory }}
- name: Run Build - name: Run Build

View File

@ -11,6 +11,9 @@ on:
description: 'The tag to publish to on NPM.' description: 'The tag to publish to on NPM.'
type: string type: string
required: true required: true
preid:
description: 'The prerelease identifier used when doing a prerelease.'
type: string
secrets: secrets:
NPM_TOKEN: NPM_TOKEN:
required: true required: true
@ -25,6 +28,7 @@ jobs:
scope: '@ionic/core' scope: '@ionic/core'
tag: ${{ inputs.tag }} tag: ${{ inputs.tag }}
version: ${{ inputs.version }} version: ${{ inputs.version }}
preid: ${{ inputs.preid }}
working-directory: 'core' working-directory: 'core'
token: ${{ secrets.NPM_TOKEN }} token: ${{ secrets.NPM_TOKEN }}
- name: Cache Built @ionic/core - name: Cache Built @ionic/core
@ -56,6 +60,7 @@ jobs:
scope: '@ionic/docs' scope: '@ionic/docs'
tag: ${{ inputs.tag }} tag: ${{ inputs.tag }}
version: ${{ inputs.version }} version: ${{ inputs.version }}
preid: ${{ inputs.preid }}
working-directory: 'docs' working-directory: 'docs'
token: ${{ secrets.NPM_TOKEN }} token: ${{ secrets.NPM_TOKEN }}
@ -75,6 +80,7 @@ jobs:
scope: '@ionic/angular' scope: '@ionic/angular'
tag: ${{ inputs.tag }} tag: ${{ inputs.tag }}
version: ${{ inputs.version }} version: ${{ inputs.version }}
preid: ${{ inputs.preid }}
working-directory: 'angular' working-directory: 'angular'
folder: './dist' folder: './dist'
token: ${{ secrets.NPM_TOKEN }} token: ${{ secrets.NPM_TOKEN }}
@ -101,6 +107,7 @@ jobs:
scope: '@ionic/react' scope: '@ionic/react'
tag: ${{ inputs.tag }} tag: ${{ inputs.tag }}
version: ${{ inputs.version }} version: ${{ inputs.version }}
preid: ${{ inputs.preid }}
working-directory: 'packages/react' working-directory: 'packages/react'
token: ${{ secrets.NPM_TOKEN }} token: ${{ secrets.NPM_TOKEN }}
- name: Cache Built @ionic/react - name: Cache Built @ionic/react
@ -126,6 +133,7 @@ jobs:
scope: '@ionic/vue' scope: '@ionic/vue'
tag: ${{ inputs.tag }} tag: ${{ inputs.tag }}
version: ${{ inputs.version }} version: ${{ inputs.version }}
preid: ${{ inputs.preid }}
working-directory: 'packages/vue' working-directory: 'packages/vue'
token: ${{ secrets.NPM_TOKEN }} token: ${{ secrets.NPM_TOKEN }}
- name: Cache Built @ionic/vue - name: Cache Built @ionic/vue
@ -157,6 +165,7 @@ jobs:
scope: '@ionic/angular-server' scope: '@ionic/angular-server'
tag: ${{ inputs.tag }} tag: ${{ inputs.tag }}
version: ${{ inputs.version }} version: ${{ inputs.version }}
preid: ${{ inputs.preid }}
working-directory: 'packages/angular-server' working-directory: 'packages/angular-server'
folder: './dist' folder: './dist'
token: ${{ secrets.NPM_TOKEN }} token: ${{ secrets.NPM_TOKEN }}
@ -183,6 +192,7 @@ jobs:
scope: '@ionic/react-router' scope: '@ionic/react-router'
tag: ${{ inputs.tag }} tag: ${{ inputs.tag }}
version: ${{ inputs.version }} version: ${{ inputs.version }}
preid: ${{ inputs.preid }}
working-directory: 'packages/react-router' working-directory: 'packages/react-router'
token: ${{ secrets.NPM_TOKEN }} token: ${{ secrets.NPM_TOKEN }}
@ -208,5 +218,6 @@ jobs:
scope: '@ionic/vue-router' scope: '@ionic/vue-router'
tag: ${{ inputs.tag }} tag: ${{ inputs.tag }}
version: ${{ inputs.version }} version: ${{ inputs.version }}
preid: ${{ inputs.preid }}
working-directory: 'packages/vue-router' working-directory: 'packages/vue-router'
token: ${{ secrets.NPM_TOKEN }} token: ${{ secrets.NPM_TOKEN }}

View File

@ -38,6 +38,7 @@ jobs:
with: with:
tag: ${{ inputs.tag }} tag: ${{ inputs.tag }}
version: ${{ inputs.version }} version: ${{ inputs.version }}
preid: ${{ inputs.preid }}
secrets: secrets:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} NPM_TOKEN: ${{ secrets.NPM_TOKEN }}