File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -481,3 +481,21 @@ help-me:
481481 @echo " https://github.com/hyperpolymath/ipv6-tools/issues/new"
482482 @echo ""
483483 @echo "Include the output of 'just doctor' in your report."
484+
485+
486+ # Print the current CRG grade (reads from READINESS.md '**Current Grade:** X' line)
487+ crg-grade:
488+ @grade=$$ (grep -oP '(?<=\*\*Current Grade:\*\* )[A-FX]' READINESS.md 2>/dev/null | head -1); \
489+ [ -z "$$ grade" ] && grade="X"; \
490+ echo "$$ grade"
491+
492+ # Generate a shields.io badge markdown for the current CRG grade
493+ # Looks for '**Current Grade:** X' in READINESS.md; falls back to X
494+ crg-badge:
495+ @grade=$$ (grep -oP '(?<=\*\*Current Grade:\*\* )[A-FX]' READINESS.md 2>/dev/null | head -1); \
496+ [ -z "$$ grade" ] && grade="X"; \
497+ case "$$ grade" in \
498+ A) color="brightgreen" ;; B) color="green" ;; C) color="yellow" ;; \
499+ D) color="orange" ;; E) color="red" ;; F) color="critical" ;; \
500+ *) color="lightgrey" ;; esac; \
501+ echo "[](https://github.com/hyperpolymath/standards/tree/main/component-readiness-grades)"
You can’t perform that action at this time.
0 commit comments