Skip to content

Commit

Permalink
Merge PR #1 from 'nodech/pkg-ci'
Browse files Browse the repository at this point in the history
  • Loading branch information
nodech committed Jul 6, 2023
2 parents 21cf9c7 + 114a6d7 commit 49eb4bf
Show file tree
Hide file tree
Showing 4 changed files with 94 additions and 2 deletions.
3 changes: 2 additions & 1 deletion .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@
},
"rules": {
"max-len": "off",
"prefer-arrow-callback": "off"
"prefer-arrow-callback": "off",
"no-return-assign": "off"
}
}
],
Expand Down
48 changes: 48 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Build

on: [push, pull_request]

jobs:
lint:
name: Lint
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Setup
uses: actions/setup-node@v3
with:
node-version: 20.x

- name: Install tools
run: npm install --location=global bslint

- name: Install dependencies
run: npm install

- name: Lint
run: npm run lint

test:
name: Test
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
node: [16.x, 18.x, 20.x]

steps:
- uses: actions/checkout@v3

- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}

- name: Install dependencies
run: npm install

- name: Test
run: npm test

43 changes: 43 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"author": "Christopher Jeffrey <chjjeffrey@gmail.com>",
"main": "./lib/bs32.js",
"scripts": {
"lint": "eslint lib/ test/ || exit 0",
"lint": "eslint lib/ test/",
"test": "bmocha --reporter spec test/*-test.js"
},
"dependencies": {
Expand Down

0 comments on commit 49eb4bf

Please sign in to comment.