add lint action

This commit is contained in:
Anantha Kumaran 2022-05-07 20:51:32 +05:30
parent 518d48a6cc
commit bbc830a399
2 changed files with 18 additions and 0 deletions

17
.github/workflows/test.yml vendored Normal file
View File

@ -0,0 +1,17 @@
name: Test
on:
- push
- pull_request
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2.4.0
- uses: cachix/install-nix-action@v15
with:
nix_path: nixpkgs=channel:nixos-unstable
- run: |
nix-shell --run 'npm install'
nix-shell --run 'make lint'

View File

@ -13,3 +13,4 @@ publish:
lint:
./node_modules/.bin/prettier --check web/src
./node_modules/.bin/eslint web/src --ext .js,.jsx,.ts,.tsx
test -z $$(gofmt -l .)