Skip to content

Upgrade sdk version #246

Upgrade sdk version

Upgrade sdk version #246

# This program has been developed by students from the bachelor Computer Science at Utrecht University within the Software Project course.
# © Copyright Utrecht University (Department of Information and Computing Sciences)
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
name: Format/Lint Checks
on:
workflow_dispatch:
push:
branches: ['master', 'dev']
pull_request:
branches: ['master', 'dev']
jobs:
# Install and cache npm dependencies
install-cache:
runs-on: ubuntu-latest
steps:
- name: Checkout Commit
uses: actions/checkout@v3
- name: Cache node modules
uses: actions/cache@v3
id: npm-cache
with:
path: |
**/node_modules
key: ${{ runner.os }}-build-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build
- name: Install dependencies if cache invalid
if: steps.npm-cache.outputs.cache-hit != 'true'
run: npm ci
format-and-lint-check:
runs-on: ubuntu-latest
needs: install-cache
steps:
- uses: actions/checkout@v3
- name: Restore npm cache
uses: actions/cache@v3
id: npm-cache
with:
path: |
**/node_modules
key: ${{ runner.os }}-build-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build
- name: run formatting check
run: npx prettier --check ./src
- name: run ESlint check
run: npx eslint ./src