-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Remove OptiPNG from local dev
- Loading branch information
Showing
2 changed files
with
0 additions
and
15 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,4 @@ | ||
#!/bin/sh | ||
. "$(dirname "$0")/_/husky.sh" | ||
|
||
# Check if staged files contain any added or modified PNGs - skip when merging | ||
if \ | ||
git rev-parse -q --verify MERGE_HEAD \ | ||
&& git diff --cached --name-status | grep '^[AM]' | grep -q '.png$' | ||
then | ||
# Error if OptiPNG is not installed | ||
if ! command -v optipng >/dev/null; then | ||
echo "PNG files must be optimized before being committed, but OptiPNG is not installed! Fix this with \`brew/apt install optipng\`." | ||
exit 1 | ||
fi | ||
fi | ||
|
||
pnpm lint-staged |
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