Merge pull request #8 from tsshogi/feature/docs #26
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: Continuous Integration | |
on: | |
push: | |
jobs: | |
commitlint: | |
name: CommitLint | |
if: github.event.action != 'closed' || github.event.pull_request.merged != true | |
runs-on: ubuntu-24.04 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Bun | |
uses: oven-sh/setup-bun@v1 | |
with: | |
bun-version: latest | |
- name: Install commitlint | |
run: | | |
bun install conventional-changelog-conventionalcommits | |
bun install commitlint@latest | |
- name: Validate current commit (last commit) with commitlint | |
if: github.event_name == 'push' | |
run: bunx commitlint --last --verbose | |
- name: Validate PR commits with commitlint | |
if: github.event_name == 'pull_request' | |
run: bunx commitlint --from ${{ github.event.pull_request.head.sha }}~${{ github.event.pull_request.commits }} --to ${{ github.event.pull_request.head.sha }} --verbose | |
check: | |
name: Code Check | |
runs-on: ubuntu-24.04 | |
if: github.event.action != 'closed' || github.event.pull_request.merged != true | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Bun | |
uses: oven-sh/setup-bun@v1 | |
with: | |
bun-version: latest | |
- name: Format | |
run: | | |
bunx @biomejs/biome format src | |
- name: Lint | |
run: | | |
bunx @biomejs/biome lint src |