Download hooks/pre-commit from TTOPM/belel-protocol: direct link, hf CLI and curl.
- Browser
- Download file 584 Bytes
-
https://huggingface.co/TTOPM/belel-protocol/resolve/main/hooks/pre-commit
- Command line
-
hf download hf://TTOPM/belel-protocol/hooks/pre-commit
-
curl -L -o pre-commit https://huggingface.co/TTOPM/belel-protocol/resolve/main/hooks/pre-commit
584 Bytes
| set -e | |
| PY=${PYTHON:-python3} | |
| BASE="belel-justice-covenant" | |
| # 1) Block destructive edits (append-only enforcement) | |
| if [ -f "$BASE/protocol_instructions/revisionism_resistor.py" ]; then | |
| $PY "$BASE/protocol_instructions/revisionism_resistor.py" | |
| fi | |
| # 2) Verify or create checksums | |
| if [ -f "$BASE/tools/generate_checksums.py" ]; then | |
| if [ -f "$BASE/signing/checksums.txt" ]; then | |
| $PY "$BASE/tools/generate_checksums.py" --verify | |
| else | |
| echo "[pre-commit] No checksums.txt found — creating baseline." | |
| $PY "$BASE/tools/generate_checksums.py" | |
| fi | |
| fi | |