You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
#!/bin/sh
|
|
FILES=$(git diff --cached --name-only --diff-filter=ACMR | sed 's| |\\ |g')
|
|
[ -z "$FILES" ] && exit 0
|
|
|
|
# Lint and format staged files
|
|
echo "$FILES" | xargs pnpm exec oxlint --fix
|
|
echo "$FILES" | xargs pnpm exec oxfmt --write
|
|
echo "$FILES" | xargs git add
|
|
|
|
exit 0
|