blob: 9649a403993dbecad5d74dcd27ca620d5e4301e6 [file] [log] [blame]
Patrick Williams91f8ad32020-12-29 17:19:12 -06001#!/bin/bash
Derick Montaguebf2131f2020-05-29 11:21:36 -05002# Run GUI Linting and Formatting as part of the CI Build process
3#
4# This is a short term solution. The long term solution to will be to
5# add much of this to the build script.
6#
7
8set -e
9
Patrick Williams91f8ad32020-12-29 17:19:12 -060010# When called from openbmc-build-scripts, the `pwd` could be anywhere, but
11# the root of the repo is passed in the first argument. Switch to the repo
12# root so npm/git run in the right place.
13if [ -n "$1" ]; then
14 cd "$1"
15fi
16
Derick Montaguebf2131f2020-05-29 11:21:36 -050017npm ci
18npm run lint
Patrick Williams91f8ad32020-12-29 17:19:12 -060019git --no-pager diff --exit-code