feat(eslint-config): update configs and improve type definitions #561
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
# Continuous Integration jobs for changes pointed to main. | |
--- | |
name: Main | |
'on': | |
merge_group: | |
push: | |
branches: [main] | |
pull_request: | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.number || github.ref }} | |
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
permissions: | |
contents: read | |
jobs: | |
ci: | |
name: CI | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: Prepare job | |
uses: ./.github/actions/pnpm-install | |
- name: Check formatting | |
run: pnpm run check-format | |
- name: Lint | |
run: pnpm run lint | |
- name: Run tests | |
run: pnpm run test | |
release: | |
name: Release | |
if: github.repository == 'bfra-me/works' && github.ref == 'refs/heads/main' | |
needs: | |
- ci | |
permissions: | |
contents: read | |
id-token: write | |
runs-on: ubuntu-latest | |
steps: | |
- id: get-workflow-access-token | |
name: Get Workflow Access Token | |
uses: actions/create-github-app-token@5d869da34e18e7287c1daad50e0b8ea0f506ce69 # v1.11.0 | |
with: | |
app-id: ${{ secrets.APPLICATION_ID }} | |
private-key: ${{ secrets.APPLICATION_PRIVATE_KEY }} | |
owner: ${{ github.repository_owner }} | |
- name: Setup Git user | |
run: | | |
git config --global user.email '118100583+bfra-me[bot]@users.noreply.github.com' | |
git config --global user.name 'bfra-me[bot]' | |
- name: Checkout repository | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
with: | |
fetch-depth: 0 | |
token: ${{ steps.get-workflow-access-token.outputs.token }} | |
- name: Prepare job | |
uses: ./.github/actions/pnpm-install | |
- name: Perform a dry run of `pnpm publish` | |
run: pnpm -r publish --dry-run | |
- name: Create Release Pull Request or Publish to npm | |
uses: changesets/action@c8bada60c408975afd1a20b3db81d6eee6789308 # v1.4.9 | |
with: | |
commit: 'chore(changesets): publish packages' | |
publish: pnpm publish-changesets | |
setupGitUser: false | |
title: 'chore(🦋📦): publish packages' | |
version: pnpm version-changesets | |
env: | |
GITHUB_TOKEN: ${{ steps.get-workflow-access-token.outputs.token }} | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} |