opencode_offline/scripts/hooks

16 lines
204 B
Plaintext
Raw Normal View History

#!/bin/sh
2025-06-19 12:20:03 +08:00
if [ ! -d ".git" ]; then
exit 0
fi
mkdir -p .git/hooks
cat > .git/hooks/pre-push << 'EOF'
#!/bin/sh
bun run typecheck
EOF
chmod +x .git/hooks/pre-push
echo "✅ Pre-push hook installed"