v2.0.2 #7
Workflow file for this run
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: Publish Release | |
on: | |
release: | |
types: [published] | |
workflow_dispatch: | |
inputs: | |
tag-name: | |
description: Tag name that the major tag will point to | |
required: true | |
debug: | |
type: choice | |
description: Debug mode | |
required: false | |
options: | |
- 'true' | |
- 'false' | |
env: | |
DEBUG: ${{ inputs.debug || secrets.ACTIONS_RUNNER_DEBUG || vars.ACTIONS_RUNNER_DEBUG || secrets.ACTIONS_STEP_DEBUG || vars.ACTIONS_STEP_DEBUG || false }} | |
TAG_NAME: ${{ github.event.inputs.tag-name || github.event.release.tag_name }} | |
jobs: | |
build-publish-tag: | |
name: Build, Publish and Tag | |
runs-on: ubuntu-latest | |
# permissions: | |
# contents: write | |
steps: | |
- name: 🩺 Debug | |
if: ${{ env.DEBUG == 'true' }} | |
uses: raven-actions/debug@13e7c5b2e0436a1b85276087eba43ec7d46bd955 # v1.1.0 | |
with: | |
vars-context: ${{ toJson(vars) }} | |
secrets-context: ${{ toJson(secrets) }} | |
needs-context: ${{ toJson(needs) }} | |
inputs-context: ${{ toJson(inputs) }} | |
- name: 🔑 Get Token | |
uses: actions/create-github-app-token@c1a285145b9d317df6ced56c09f525b5c2b6f755 # v1.11.1 | |
id: get-token | |
with: | |
app-id: ${{ secrets.ORG_BOT_APP_ID }} | |
private-key: ${{ secrets.ORG_BOT_PRIVATE_KEY }} | |
- name: ⤵️ Checkout | |
uses: actions/checkout@v4 | |
with: | |
token: ${{ steps.get-token.outputs.token }} | |
- name: 🚧 Setup pnpm | |
uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0 | |
with: | |
version: 9 | |
run_install: false | |
- name: 🚧 Setup Node | |
uses: actions/setup-node@v4 | |
with: | |
node-version-file: .node-version | |
cache: pnpm | |
- name: 🔀 Install dependencies | |
run: pnpm deps:ci | |
- name: 🏗️ Build | |
run: pnpm build:ci | |
- name: 🤖 Get bot details | |
id: bot-details | |
uses: raven-actions/bot-details@v1 | |
with: | |
bot-slug-name: ${{ steps.get-token.outputs.app-slug }} | |
- name: 🚀 Publish and Tag Action | |
uses: ./ | |
with: | |
github_token: ${{ steps.get-token.outputs.token }} | |
tag_name: ${{ env.TAG_NAME }} | |
rewrite_tags: true | |
latest: true | |
git_commit_message: ${{ format('🚀 {0} release', env.TAG_NAME) }} | |
git_author_name: ${{ steps.bot-details.outputs.name }} | |
git_author_email: ${{ steps.bot-details.outputs.email }} | |
git_committer_name: ${{ steps.bot-details.outputs.name }} | |
git_committer_email: ${{ steps.bot-details.outputs.email }} |