Skip to content

Commit

Permalink
Merge pull request #4 from CartoDB/chore/ci
Browse files Browse the repository at this point in the history
chore(ci): Add basic CI
  • Loading branch information
donmccurdy authored Jun 24, 2024
2 parents 94c73d0 + 57bc1a2 commit a6b5fa5
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 3 deletions.
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
dist
coverage
32 changes: 32 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: CI

on:
push:
branches: [main]
pull_request:
branches: [main]

jobs:
build:
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [18.x, 20.x, 22.x]

env:
CI: true
LINT: ${{ matrix.node-version == '22.x' && true || false }}

steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- run: corepack enable
- run: yarn install
- run: yarn build
- run: yarn test
- run: yarn lint
if: ${{ env.LINT == 'true' }}
8 changes: 5 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,12 @@
"build": "microbundle --format cjs,modern --no-compress --define VERSION=$npm_package_version",
"build:watch": "microbundle watch --format cjs,modern --no-compress --define VERSION=$npm_package_version",
"dev": "concurrently \"yarn build:watch\" \"vite --config examples/vite.config.ts --open\"",
"test": "vitest --typecheck",
"test": "vitest run --typecheck",
"test:watch": "vitest watch --typecheck",
"coverage": "vitest run --coverage",
"clean": "rimraf dist/*",
"format": "prettier \"**/*.{cjs,html,js,json,md,ts}\" --ignore-path ./.eslintignore --write"
"lint": "prettier \"**/*.{cjs,html,js,json,md,ts}\" --ignore-path ./.eslintignore --check",
"format": "prettier \"**/*.{cjs,html,js,json,md,ts}\" --ignore-path ./.eslintignore --write",
"clean": "rimraf dist/*"
},
"devDependencies": {
"@deck.gl/aggregation-layers": "^9.0.14",
Expand Down

0 comments on commit a6b5fa5

Please sign in to comment.