mirror of
https://github.com/getnora-io/nora.git
synced 2026-04-12 06:50:31 +00:00
chore: add pre-commit hook to prevent sensitive file commits
- Whitelist approach: only known safe extensions allowed (.rs, .toml, .yml, etc.) - Block sensitive patterns (.env, .key, .pem, secrets, credentials) - Warn but allow .md files - Check only NEW files, modifications to tracked files always allowed - Block large files (>5MB) with warning - Run cargo fmt check on Rust files - Update CONTRIBUTING.md with hook setup instructions
This commit is contained in:
@@ -14,6 +14,9 @@ Thank you for your interest in contributing to NORA!
|
||||
# Install Rust (if needed)
|
||||
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
|
||||
|
||||
# Enable pre-commit hooks (important!)
|
||||
git config core.hooksPath .githooks
|
||||
|
||||
# Build
|
||||
cargo build
|
||||
|
||||
|
||||
Reference in New Issue
Block a user