lp1978049: add ng lint to github actions
authorJane Sandberg <js7389@princeton.edu>
Thu, 9 Jun 2022 03:56:33 +0000 (20:56 -0700)
committerGalen Charlton <gmc@equinoxOLI.org>
Wed, 29 Jun 2022 20:17:14 +0000 (16:17 -0400)
Signed-off-by: Jane Sandberg <js7389@princeton.edu>
Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>

.github/workflows/ng-lint.yml [new file with mode: 0644]

diff --git a/.github/workflows/ng-lint.yml b/.github/workflows/ng-lint.yml
new file mode 100644 (file)
index 0000000..a607f3a
--- /dev/null
@@ -0,0 +1,26 @@
+name: Run ng lint
+on:
+  push:
+    paths:
+      - 'Open-ILS/src/eg2/**'
+  pull_request:
+    paths:
+      - 'Open-ILS/src/eg2/**'
+defaults:
+  run:
+    working-directory: Open-ILS/src/eg2
+jobs:
+  lint:
+    name: Run Angular linter
+    runs-on: ubuntu-latest
+    steps:
+      - uses: actions/checkout@v2
+      - uses: actions/setup-node@v3
+        with:
+          node-version: 14
+          cache: 'npm'
+          cache-dependency-path: Open-ILS/src/eg2/package-lock.json
+      - name: Install dependencies
+        run: npm ci --ignore-scripts
+      - name: lint
+        run: npx ng lint