50 lines
913 B
YAML
50 lines
913 B
YAML
name: Dragon Item Parser CI
|
|
|
|
on:
|
|
push:
|
|
paths:
|
|
- 'dragon-item-parser/**'
|
|
branches: [main]
|
|
pull_request:
|
|
paths:
|
|
- 'dragon-item-parser/**'
|
|
branches: [main]
|
|
|
|
jobs:
|
|
build-and-test:
|
|
runs-on: ubuntu-latest
|
|
|
|
defaults:
|
|
run:
|
|
working-directory: dragon-item-parser
|
|
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: '20'
|
|
|
|
- name: Install dependencies
|
|
run: npm ci
|
|
|
|
- name: Check formatting
|
|
run: npm run format:check
|
|
|
|
- name: Run linting
|
|
run: npm run lint
|
|
|
|
- name: Run tests
|
|
run: npm test
|
|
|
|
- name: Build
|
|
run: npm run build
|
|
|
|
- name: Verify build output
|
|
run: |
|
|
test -f dist/index.js
|
|
test -f dist/index.d.ts
|
|
test -f dist/item.js
|
|
test -f dist/item.d.ts
|