Skip to content

release-without-pr-only #1

release-without-pr-only

release-without-pr-only #1

name: release-without-pr-only
on: workflow_dispatch
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup
uses: ./.github/actions/setup
- name: Build
run: yarn build
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup
uses: ./.github/actions/setup
- name: Lint
run: yarn lint
release:
name: Release
runs-on: ubuntu-latest
needs: [build, lint]
# (1) Configure GITHUB_TOKEN with write permissions
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
# (2) Fetch all history so that release-it can determine the version
fetch-depth: 0
- name: Setup
uses: ./.github/actions/setup
# (3) Configure Git user
- name: Configure Git User
run: |
git config --global user.name "${GITHUB_ACTOR}"
git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com"
- name: Release
run: yarn release
env:
# (4) Make GITHUB_TOKEN available to release-it
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}