Release #726
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
workflow_dispatch: | |
inputs: | |
package: | |
description: 'Package' | |
required: true | |
type: choice | |
options: | |
- anatomy | |
- react | |
- solid | |
- vue | |
increment: | |
description: 'Increment' | |
required: true | |
default: 'patch' | |
type: choice | |
options: | |
- major | |
- minor | |
- patch | |
preRelease: | |
description: 'Pre Release' | |
required: true | |
default: 'skip' | |
type: choice | |
options: | |
- create | |
- continue | |
- skip | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: oven-sh/setup-bun@v2 | |
- name: Setup Git User | |
shell: bash | |
run: | | |
git config --global user.name "$(git --no-pager log --format=format:'%an' -n 1)" | |
git config --global user.email "$(git --no-pager log --format=format:'%ae' -n 1)" | |
- name: Install Dependencies | |
run: bun install | |
- name: Build | |
run: bun ${{ github.event.inputs.package }} build | |
- name: Create Pre-Release | |
if: github.event.inputs.preRelease == 'create' | |
run: bun ${{ github.event.inputs.package }} release-it ${{ github.event.inputs.increment }} --preRelease=beta --ci | |
env: | |
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} | |
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} | |
- name: Continue Pre-Release | |
if: github.event.inputs.preRelease == 'continue' | |
run: bun ${{ github.event.inputs.package }} release-it --preRelease --ci | |
env: | |
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} | |
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} | |
- name: Release | |
if: github.event.inputs.preRelease == 'skip' | |
run: bun ${{ github.event.inputs.package }} release-it --ci --increment ${{ github.event.inputs.increment }} | |
env: | |
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} | |
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} | |
- name: Notification | |
if: github.event.inputs.preRelease == 'skip' | |
uses: slackapi/[email protected] | |
with: | |
payload: | | |
{ | |
"package_name": "@ark-ui/${{ github.event.inputs.package }}", | |
"changelog_url": "https://ark-ui.com/docs/changelog/${{ github.event.inputs.package }}" | |
} | |
env: | |
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} |