config-guard

Validate and back up openclaw.json config edits before gateway deployment.

6|3|Updated Feb 4, 2026
One-click install
npx skills add https://github.com/jzOcb/config-guard --skill config-guard
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: config-guard
Source: https://github.com/jzOcb/config-guard/tree/main
Command: npx skills add https://github.com/jzOcb/config-guard --skill config-guard

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

Prevents OpenClaw gateway crashes caused by AI or humans editing openclaw.json without validation by enforcing backups, schema checks, and semantic guards before config changes reach the gateway.

Core Features & Use Cases

  • Auto-backup and rollback: Captures timestamped copies before edits and restores them automatically if the gateway health check fails after apply --restart flows.
  • Deep validation: Runs JSON syntax, schema-required fields (commands.native*), semantic checks (model names, browser profile color, placeholders), critical field diff warnings, and hooks into git commits for staged config files.
  • Safe patch workflows: Provides scripts for apply, rollback, diff, and safe-config-patch that merge patches, validate merged results, signal the gateway to reload, and warn about critical field removals.

Quick Start

Ask the guard to run scripts/config-guard.sh check on your openclaw.json before committing any edits to keep the gateway safe.

Frequently Asked Questions about config-guard

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I prevent OpenClaw gateway crashes when editing openclaw.json?

Prevent OpenClaw gateway crashes by running preflight validation scripts on openclaw.json before applying edits. The process enforces JSON syntax, schema-required fields, and semantic checks to ensure safe deployment and stop config crashes before they reach the runtime.

How do I automatically rollback a bad OpenClaw config deployment?

Automatically rollback a bad OpenClaw config deployment by capturing timestamped backups before edits. If the gateway health check fails after an apply and restart flow, the system restores the previous valid configuration automatically to recover service.

Can I validate openclaw.json staged files with git hooks before committing?

Yes, you can validate openclaw.json staged files with git hooks. The validation script hooks into git commits to run JSON syntax checks, schema-required field verification, and semantic guards on staged config files before they are committed.

What is a safe config patch workflow for critical OpenClaw gateway fields?

A safe config patch workflow for critical OpenClaw gateway fields merges patches, validates the merged results, signals the gateway to reload, and warns about critical field removals. It ensures deep validation of model names and browser profiles before deployment.

Does OpenClaw config validation check semantic rules or just JSON syntax?

OpenClaw config validation checks both JSON syntax and semantic rules. The deep validation process verifies schema-required fields like commands.native, checks model names and browser profile colors, and flags critical field diffs to prevent invalid configurations.

Why does my OpenClaw gateway health check fail after a config edit?

Your OpenClaw gateway health check fails after a config edit if the new openclaw.json contains invalid schema, unsupported model names, or broken placeholders. Running a preflight check script before applying edits identifies these issues to prevent gateway downtime.