fix: ci #4
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: Node.js CI | |
on: | |
push: | |
branches: ["main"] | |
pull_request: | |
branches: ["main"] | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [18.x, 20.x] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup Node.js environment | |
uses: actions/[email protected] | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Setup pnpm | |
uses: pnpm/[email protected] | |
with: | |
version: 8 | |
- name: Clone KermanX/slidev | |
run: git clone https://github.com/KermanX/slidev | |
working-directory: ../ | |
- name: Install KermanX/slidev | |
run: pnpm i | |
working-directory: ../slidev | |
- name: Build KermanX/slidev | |
run: pnpm build | |
working-directory: ../slidev | |
- name: Install deps | |
run: | | |
pnpm install | |
pnpm i ../slidev/packages/parser | |
pnpm i -D ../slidev/packages/types | |
- name: Run tests | |
run: pnpm test |