aboutsummaryrefslogtreecommitdiffstats
path: root/CLAUDE.md
diff options
context:
space:
mode:
Diffstat (limited to 'CLAUDE.md')
-rw-r--r--CLAUDE.md29
1 files changed, 29 insertions, 0 deletions
diff --git a/CLAUDE.md b/CLAUDE.md
index 8e29936..81fda40 100644
--- a/CLAUDE.md
+++ b/CLAUDE.md
@@ -186,6 +186,35 @@ git commit -m'<package-name>: add version X.Y.Z'
---
+## Git Hooks
+
+Versioned source lives in `.extras/hooks/`. They are NOT auto-installed
+(git ignores `.git/hooks/` only if `core.hooksPath` is unset; the user's
+global `core.hooksPath` dispatches to `.git/hooks/<name>` when executable).
+After a fresh clone, install them:
+
+```bash
+cp .extras/hooks/* .git/hooks/ && chmod 0755 .git/hooks/{pre,post}-commit
+```
+
+- `pre-commit` — runs `sbolint` on each changed package; aborts the commit on
+ any error. Also auto-removes staged source-archive symlinks and blocks
+ staged regular source archives (`*.tar.*`, `*.zip`, `*.deb`, etc.). Skip
+ with `SBOLINT=no git commit ...`.
+- `post-commit` — for each added/updated `*.SlackBuild`, offers to build the
+ SBo submission tarball into `SBo/<package>.tar.gz`.
+
+### `SBO_ARCHIVE` (non-interactive archive answer)
+
+`post-commit` normally prompts on a TTY. To answer without one (agents,
+scripts), set `SBO_ARCHIVE`:
+
+- `SBO_ARCHIVE=yes git commit ...` — build the tarball, no prompt
+- `SBO_ARCHIVE=no git commit ...` — skip, no prompt
+- unset + TTY → interactive prompt; unset + no TTY → skip
+
+---
+
## Commit Conventions
- One commit per package add/update