Skip to content

Commit a2b5110

Browse files
Chore/cicd optimizations (#32)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 589807f commit a2b5110

2 files changed

Lines changed: 1 addition & 114 deletions

File tree

contractile.just

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,5 +71,3 @@ trust-no-secrets-committed:
7171
# Containerfile base images use pinned digests
7272
trust-container-images-pinned:
7373
test ! -f Containerfile || grep -q '@sha256:' Containerfile
74-
75-

Justfile renamed to justfile

Lines changed: 1 addition & 112 deletions
Original file line numberDiff line numberDiff line change
@@ -219,115 +219,4 @@ build-riscv:
219219

220220
# Run panic-attacker pre-commit scan
221221
assail:
222-
@command -v panic-attack >/dev/null 2>&1 && panic-attack assail . || echo "panic-attack not found — install from https://github.com/hyperpolymath/panic-attacker"
223-
224-
# ═══════════════════════════════════════════════════════════════════════════════
225-
# ONBOARDING & DIAGNOSTICS
226-
# ═══════════════════════════════════════════════════════════════════════════════
227-
228-
# Check all required toolchain dependencies and report health
229-
doctor:
230-
#!/usr/bin/env bash
231-
echo "═══════════════════════════════════════════════════"
232-
echo " Conative Gating Doctor — Toolchain Health Check"
233-
echo "═══════════════════════════════════════════════════"
234-
echo ""
235-
PASS=0; FAIL=0; WARN=0
236-
check() {
237-
local name="$1" cmd="$2" min="$3"
238-
if command -v "$cmd" >/dev/null 2>&1; then
239-
VER=$("$cmd" --version 2>&1 | head -1)
240-
echo " [OK] $name$VER"
241-
PASS=$((PASS + 1))
242-
else
243-
echo " [FAIL] $name — not found (need $min+)"
244-
FAIL=$((FAIL + 1))
245-
fi
246-
}
247-
check "just" just "1.25"
248-
check "git" git "2.40"
249-
check "Rust (cargo)" cargo "1.80"
250-
check "Zig" zig "0.13"
251-
# Optional tools
252-
if command -v panic-attack >/dev/null 2>&1; then
253-
echo " [OK] panic-attack — available"
254-
PASS=$((PASS + 1))
255-
else
256-
echo " [WARN] panic-attack — not found (pre-commit scanner)"
257-
WARN=$((WARN + 1))
258-
fi
259-
echo ""
260-
echo " Result: $PASS passed, $FAIL failed, $WARN warnings"
261-
if [ "$FAIL" -gt 0 ]; then
262-
echo " Run 'just heal' to attempt automatic repair."
263-
exit 1
264-
fi
265-
echo " All required tools present."
266-
267-
# Attempt to automatically install missing tools
268-
heal:
269-
#!/usr/bin/env bash
270-
echo "═══════════════════════════════════════════════════"
271-
echo " Conative Gating Heal — Automatic Tool Installation"
272-
echo "═══════════════════════════════════════════════════"
273-
echo ""
274-
if ! command -v cargo >/dev/null 2>&1; then
275-
echo "Installing Rust via rustup..."
276-
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
277-
source "$HOME/.cargo/env"
278-
fi
279-
if ! command -v just >/dev/null 2>&1; then
280-
echo "Installing just..."
281-
cargo install just 2>/dev/null || echo "Install just from https://just.systems"
282-
fi
283-
echo ""
284-
echo "Heal complete. Run 'just doctor' to verify."
285-
286-
# Guided tour of the project structure and key concepts
287-
tour:
288-
#!/usr/bin/env bash
289-
echo "═══════════════════════════════════════════════════"
290-
echo " Conative Gating — Guided Tour"
291-
echo "═══════════════════════════════════════════════════"
292-
echo ""
293-
echo 'Jonathan D.A. Jewell <jonathan@hyperpolymath.org>'
294-
echo ""
295-
echo "Key directories:"
296-
echo " src/ Source code"
297-
echo " ffi/ Foreign function interface (Zig)"
298-
echo " src/abi/ Idris2 ABI definitions"
299-
echo " docs/ Documentation"
300-
echo " .github/workflows/ CI/CD workflows"
301-
echo " contractiles/ Must/Trust/Dust contracts"
302-
echo " .machine_readable/ Machine-readable metadata"
303-
echo " examples/ Usage examples"
304-
echo ""
305-
echo "Quick commands:"
306-
echo " just doctor Check toolchain health"
307-
echo " just heal Fix missing tools"
308-
echo " just help-me Common workflows"
309-
echo " just default List all recipes"
310-
echo ""
311-
echo "Read more: README.adoc, EXPLAINME.adoc"
312-
313-
# Show help for common workflows
314-
help-me:
315-
#!/usr/bin/env bash
316-
echo "═══════════════════════════════════════════════════"
317-
echo " Conative Gating — Common Workflows"
318-
echo "═══════════════════════════════════════════════════"
319-
echo ""
320-
echo "FIRST TIME SETUP:"
321-
echo " just doctor Check toolchain"
322-
echo " just heal Fix missing tools"
323-
echo ""
324-
echo "DEVELOPMENT:"
325-
echo " cargo build Build the project"
326-
echo " cargo test Run tests"
327-
echo ""
328-
echo "PRE-COMMIT:"
329-
echo " just assail Run panic-attacker scan"
330-
echo ""
331-
echo "LEARN:"
332-
echo " just tour Guided project tour"
333-
echo " just default List all recipes"
222+
@command -v panic-attack >/dev/null 2>&1 && panic-attack assail . || echo "panic-attack not found — install from https://github.com/hyperpolymath/panic-attacker"

0 commit comments

Comments
 (0)