-
Notifications
You must be signed in to change notification settings - Fork 0
/
check
executable file
·34 lines (29 loc) · 885 Bytes
/
check
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/bin/bash -e
info="\033[1;36m"
success="\033[1;32m"
clear="\033[0m"
if [ ! -z "$(git diff --name-only HEAD dawn | head -1)" ]; then
echo -e "${info}:: Checking Dawn ...${clear}"
pushd dawn &>/dev/null
npm install --quiet --also=dev
npm run --silent format:check
npm run --silent lint
popd &>/dev/null
fi
if [ ! -z "$(git diff --name-only HEAD shepherd | head -1)" ]; then
echo -e "${info}:: Checking Shepherd ...${clear}"
pushd shepherd &>/dev/null
npm install --quiet --also=dev
npm run --silent format:check
npm run --silent lint
popd &>/dev/null
fi
if [ ! -z "$(git diff --name-only HEAD runtime | head -1)" ]; then
echo -e "${info}:: Checking Runtime ...${clear}"
pushd runtime &>/dev/null
pipenv run format:check
pipenv run lint
pipenv run typecheck
popd &>/dev/null
fi
echo -e "${success}All projects passed static checks!${clear}"