feat(ci): add CI workflow for installation, linting, formatting, buil… #1
This file contains hidden or 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: CI | |
on: | |
push: | |
branches: ["*"] | |
pull_request: | |
branches: ["*"] | |
concurrency: | |
group: ci-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
install-and-check: | |
name: Install and Check | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Setup pnpm | |
uses: pnpm/action-setup@v4 | |
- name: Setup Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 22.x # Use the latest LTS version of Node.js | |
cache: "pnpm" | |
- name: Install dependencies | |
run: pnpm install | |
- name: Lint | |
run: pnpm lint | |
- name: Format check | |
run: pnpm format:check | |
- name: Build | |
run: pnpm build | |
- name: Test | |
run: pnpm test |