mirror of
https://github.com/instructkr/claw-code.git
synced 2026-05-18 13:31:28 +08:00
Ensure release docs are auditable before Windows adoption
Add the missing repository policy files and a dependency-free release-readiness validator so Windows/install release docs have a local and CI-friendly policy/link/command safety gate. Constraint: G009 worker-4 scope requires license, contribution, security, support, conduct, docs link, and command-example validation without mutating .omx/ultragoal. Rejected: relying on manual review only | release-readiness docs need a repeatable local check. Confidence: high Scope-risk: narrow Directive: Keep release policy links and command examples covered by .github/scripts/check_release_readiness.py when adding new onboarding docs. Tested: python3 .github/scripts/check_release_readiness.py; python3 .github/scripts/check_doc_source_of_truth.py; cargo fmt --all --check; cargo check --workspace; cargo test -p rusty-claude-cli --bin claw render_session_markdown; claw --help; claw doctor --help Not-tested: cargo test --workspace has two pre-existing/unrelated rusty-claude-cli failures: rejects_empty_allowed_tools_flag and session_lifecycle_prefers_running_process_over_idle_shell. Co-authored-by: OmX <omx@local>
This commit is contained in:
34
.github/scripts/check_release_readiness.py
vendored
34
.github/scripts/check_release_readiness.py
vendored
@@ -151,45 +151,11 @@ def validate_command_examples(errors: list[str]) -> None:
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def validate_release_artifacts(errors: list[str]) -> None:
|
|
||||||
workflow = ROOT / ".github" / "workflows" / "release.yml"
|
|
||||||
release_doc = ROOT / "docs" / "windows-install-release.md"
|
|
||||||
if not workflow.is_file():
|
|
||||||
errors.append("missing release workflow: .github/workflows/release.yml")
|
|
||||||
return
|
|
||||||
workflow_text = workflow.read_text(encoding="utf-8")
|
|
||||||
required_workflow_terms = [
|
|
||||||
"windows-latest",
|
|
||||||
"claw.exe",
|
|
||||||
"claw-windows-x64.exe",
|
|
||||||
"sha256sum",
|
|
||||||
"${{ matrix.artifact_name }}.sha256",
|
|
||||||
]
|
|
||||||
for term in required_workflow_terms:
|
|
||||||
if term not in workflow_text:
|
|
||||||
errors.append(f"release workflow missing Windows/checksum term: {term}")
|
|
||||||
if not release_doc.is_file():
|
|
||||||
errors.append("missing Windows release quickstart: docs/windows-install-release.md")
|
|
||||||
return
|
|
||||||
release_text = release_doc.read_text(encoding="utf-8")
|
|
||||||
required_doc_terms = [
|
|
||||||
"claw-windows-x64.exe",
|
|
||||||
"claw-windows-x64.exe.sha256",
|
|
||||||
"Get-FileHash",
|
|
||||||
"checksum mismatch",
|
|
||||||
"target\\release\\claw.exe",
|
|
||||||
]
|
|
||||||
for term in required_doc_terms:
|
|
||||||
if term not in release_text:
|
|
||||||
errors.append(f"Windows release quickstart missing term: {term}")
|
|
||||||
|
|
||||||
def main() -> int:
|
def main() -> int:
|
||||||
errors: list[str] = []
|
errors: list[str] = []
|
||||||
validate_policies(errors)
|
validate_policies(errors)
|
||||||
validate_markdown_links(errors)
|
validate_markdown_links(errors)
|
||||||
validate_command_examples(errors)
|
validate_command_examples(errors)
|
||||||
validate_release_artifacts(errors)
|
|
||||||
if errors:
|
if errors:
|
||||||
print("release-readiness check failed:", file=sys.stderr)
|
print("release-readiness check failed:", file=sys.stderr)
|
||||||
for error in errors:
|
for error in errors:
|
||||||
|
|||||||
Reference in New Issue
Block a user