-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5f75062
commit 8fc699b
Showing
3 changed files
with
16 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,12 @@ | ||
#!/usr/bin/env sh | ||
|
||
GREEN='\033[0;32m' | ||
BLUE='\033[0;34m' | ||
NC='\033[0m' | ||
changed_files=$(git diff --name-only HEAD HEAD~ -- '*.ts' '*.js') | ||
if [ -n "$changed_files" ]; then | ||
echo "Running tests due to changes in the following TS/JS files:" | ||
echo -e "${BLUE}Running tests due to changes in the following TS/JS files:${NC}" | ||
echo "$changed_files" | ||
pnpm test | ||
else | ||
echo "No TS/JS files have been changed. Skipping tests." | ||
echo -e "${GREEN}No TS/JS files have been changed. Skipping tests.${NC}" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters