← 返回 Skills 市场
ijevin

Safe Edit

作者 ijevin · GitHub ↗ · v1.0.0
cross-platform ⚠ suspicious
275
总下载
0
收藏
2
当前安装
1
版本数
在 OpenClaw 中安装
/install safe-edit
功能描述
安全配置修改辅助技能 - 在修改重要配置文件前自动设置回滚,支持多平台(Linux/macOS/FreeBSD/Windows)
安全使用建议
This skill largely does what it says — it backs up files and schedules a 15-minute rollback — but before installing or enabling it, consider: - The provided script writes under /root/.openclaw (backups, logs, scripts) and may need root or equivalent permissions to operate on system config files; ensure you are comfortable granting that level of access. - If the host lacks the 'at' command the script will try to run apt-get/yum to install it; that implies network package installs and elevated privileges. If you do not want automatic package installs, run or inspect the script manually and install dependencies yourself. - The script generates rollback scripts and scheduled tasks (at jobs, schtasks, or background sleep processes). Review the generated rollback script content (it copies backups over targets) so you know exactly what will be executed later. - The skill metadata does not declare these filesystem/scheduler requirements — treat that as an omission. Prefer running the script in a controlled environment first (non-production) and review/modify paths (BACKUP_DIR, ROLLBACK_SCRIPT) before allowing the agent to invoke it on critical targets. If you want to proceed safely: manually install and audit safe-edit.sh, create a non-root backup directory and adjust BACKUP_DIR/ROLLBACK_SCRIPT, and confirm the host's package/install behavior so the script will not perform unexpected installs.
功能分析
Type: OpenClaw Skill Name: safe-edit Version: 1.0.0 The 'safe-edit' skill is a utility designed to provide a safety net when modifying configuration files by creating backups and scheduling automatic rollbacks. It uses standard system tools like 'at' (Linux/macOS), 'schtasks' (Windows), and background subshells to restore files if a change is not confirmed within 15 minutes. While the script (safe-edit.sh) requires high privileges to access /root/ paths and potentially install the 'at' package, its logic is transparently aligned with its stated purpose and contains no evidence of data exfiltration, backdoors, or malicious intent.
能力评估
Purpose & Capability
The name/description (safe-edit = backup + delayed rollback for config edits) match the provided shell script and SKILL.md: the script creates backups, schedules a 15-minute rollback, and supports cancel/confirm operations across platforms. The functionality implemented is coherent with the stated purpose.
Instruction Scope
The SKILL.md instructs the agent to run safe-edit start/confirm/cancel on target files and to recommend safe-edit for any config edits — that is consistent with the script. The instructions do not ask the agent to read unrelated secrets or contact external endpoints. However the policy to 'always recommend' safe-edit for any config change gives the agent broad discretion to frequently schedule operations and create artifacts on the host.
Install Mechanism
There is no install spec (instruction-only) which limits remote code fetch risks. The provided shell script will attempt to call package managers (apt-get/yum) to install at if missing — this implies network package installation may occur at runtime if at is absent. That is expected for the feature, but it is an implicit side-effect not declared in metadata.
Credentials
The skill metadata declares no required env/config access, yet the script uses and writes to system paths (/root/.openclaw/backups, /root/.openclaw/scripts, /root/.openclaw/logs) and may create scheduled tasks (at, schtasks) and rollback scripts. Running these operations typically requires elevated filesystem and scheduler permissions. The mismatch between claimed 'no required config paths' and actual writes under /root is a proportionality concern that users should be aware of.
Persistence & Privilege
The skill does not set always:true and is user-invocable (normal). The script persists artifacts (backup files, rollback scripts, at jobs, scheduled tasks, background sleep PIDs) on disk and in system scheduler, which is necessary for rollback but means the skill creates persistent state and scheduled actions on the host. This behavior is expected but worth auditing before use.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install safe-edit
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /safe-edit 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
safe-edit v1.0.0 Provides an automatic rollback mechanism before editing critical configuration files. - Automatically backs up target configuration files before modification. - Sets a timed (15-minute) automatic rollback to prevent accidental misconfiguration. - Allows immediate confirmation to cancel rollback or manual rollback if needed. - Supports multiple platforms: Linux, macOS, FreeBSD, Windows. - CLI tool and clear usage guidance included to ensure safe operations with configs.
元数据
Slug safe-edit
版本 1.0.0
许可证
累计安装 2
当前安装数 2
历史版本数 1
常见问题

Safe Edit 是什么?

安全配置修改辅助技能 - 在修改重要配置文件前自动设置回滚,支持多平台(Linux/macOS/FreeBSD/Windows). 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 275 次。

如何安装 Safe Edit?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install safe-edit」即可一键安装,无需额外配置。

Safe Edit 是免费的吗?

是的,Safe Edit 完全免费(开源免费),可自由下载、安装和使用。

Safe Edit 支持哪些平台?

Safe Edit 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Safe Edit?

由 ijevin(@ijevin)开发并维护,当前版本 v1.0.0。

💬 留言讨论