@@ -353,3 +353,118 @@ audit-deps:
353353# Run panic-attacker pre-commit scan
354354assail :
355355 @ command -v panic-attack >/ dev/ null 2 >&1 && panic-attack assail . || echo " panic-attack not found — install from https://github.com/hyperpolymath/panic-attacker"
356+
357+ # ═══════════════════════════════════════════════════════════════════════════════
358+ # ONBOARDING & DIAGNOSTICS
359+ # ═══════════════════════════════════════════════════════════════════════════════
360+
361+ # Check all required toolchain dependencies and report health
362+ doctor :
363+ #!/usr/bin/env bash
364+ echo " ═══════════════════════════════════════════════════"
365+ echo " Accessibility Everywhere Doctor — Toolchain Health Check"
366+ echo " ═══════════════════════════════════════════════════"
367+ echo " "
368+ PASS=0; FAIL=0; WARN=0
369+ check() {
370+ local name=" $1" cmd=" $2" min=" $3"
371+ if command -v " $cmd" >/ dev/ null 2 >&1 ; then
372+ VER=$(" $cmd" --version 2 >&1 | head -1)
373+ echo " [OK] $name — $VER"
374+ PASS=$((PASS + 1 ))
375+ else
376+ echo " [FAIL] $name — not found (need $min+)"
377+ FAIL=$((FAIL + 1 ))
378+ fi
379+ }
380+ check " just" just " 1.25"
381+ check " git" git " 2.40"
382+ check " Deno" deno " 2.0"
383+ check " ReScript (resc)" rescript " 12.0"
384+ check " Zig" zig " 0.13"
385+ # Optional tools
386+ if command -v panic-attack >/ dev/ null 2 >&1 ; then
387+ echo " [OK] panic-attack — available"
388+ PASS=$((PASS + 1 ))
389+ else
390+ echo " [WARN] panic-attack — not found (pre-commit scanner)"
391+ WARN=$((WARN + 1 ))
392+ fi
393+ echo " "
394+ echo " Result: $PASS passed, $FAIL failed, $WARN warnings"
395+ if [ " $FAIL" -gt 0 ]; then
396+ echo " Run 'just heal' to attempt automatic repair."
397+ exit 1
398+ fi
399+ echo " All required tools present."
400+
401+ # Attempt to automatically install missing tools
402+ heal :
403+ #!/usr/bin/env bash
404+ echo " ═══════════════════════════════════════════════════"
405+ echo " Accessibility Everywhere Heal — Automatic Tool Installation"
406+ echo " ═══════════════════════════════════════════════════"
407+ echo " "
408+ if ! command -v deno >/ dev/ null 2 >&1 ; then
409+ echo " Installing Deno..."
410+ curl -fsSL https:// deno.land/ install.sh | sh
411+ fi
412+ # Install Deno dependencies
413+ echo " Installing Deno dependencies..."
414+ deno install 2 >/ dev/ null || true
415+ if ! command -v just >/ dev/ null 2 >&1 ; then
416+ echo " Installing just..."
417+ cargo install just 2 >/ dev/ null || echo " Install just from https://just.systems"
418+ fi
419+ echo " "
420+ echo " Heal complete. Run 'just doctor' to verify."
421+
422+ # Guided tour of the project structure and key concepts
423+ tour :
424+ #!/usr/bin/env bash
425+ echo " ═══════════════════════════════════════════════════"
426+ echo " Accessibility Everywhere — Guided Tour"
427+ echo " ═══════════════════════════════════════════════════"
428+ echo " "
429+ echo ' > Making web accessibility a search engine ranking factor'
430+ echo " "
431+ echo " Key directories:"
432+ echo " src/ Source code"
433+ echo " ffi/ Foreign function interface (Zig)"
434+ echo " src/abi/ Idris2 ABI definitions"
435+ echo " docs/ Documentation"
436+ echo " tests/ Test suite"
437+ echo " .github/workflows/ CI/CD workflows"
438+ echo " contractiles/ Must/Trust/Dust contracts"
439+ echo " .machine_readable/ Machine-readable metadata"
440+ echo " examples/ Usage examples"
441+ echo " "
442+ echo " Quick commands:"
443+ echo " just doctor Check toolchain health"
444+ echo " just heal Fix missing tools"
445+ echo " just help-me Common workflows"
446+ echo " just default List all recipes"
447+ echo " "
448+ echo " Read more: README.adoc, EXPLAINME.adoc"
449+
450+ # Show help for common workflows
451+ help-me :
452+ #!/usr/bin/env bash
453+ echo " ═══════════════════════════════════════════════════"
454+ echo " Accessibility Everywhere — Common Workflows"
455+ echo " ═══════════════════════════════════════════════════"
456+ echo " "
457+ echo "FIRST TIME SETUP : "
458+ echo " just doctor Check toolchain"
459+ echo " just heal Fix missing tools"
460+ echo " "
461+ echo " DEVELOPMENT:"
462+ echo " deno task dev Development server"
463+ echo " deno test Run tests"
464+ echo " "
465+ echo "PRE -COMMIT : "
466+ echo " just assail Run panic-attacker scan"
467+ echo " "
468+ echo "LEARN : "
469+ echo " just tour Guided project tour"
470+ echo " just default List all recipes"
0 commit comments