Hooks Automation
自动化 Claude Code 钩子
手动设置钩子在不同 Claude Code 项目中可能不一致。此技能指导针对任务、会话、记忆和 Git 工作流的自动化钩子配置。
安装前请停下并请求确认。
请审查安装计划,并在更改文件前获得用户明确同意。
使用我的智能体安装
将此请求复制给你的智能体,其中包含权威 Skill 页面和清单。
Review the Skillstore skill "Hooks Automation" from https://skillstore.io/skills/ruvnet-hooks-automation.md and its manifest at https://skillstore.io/api/skills/ruvnet-hooks-automation/manifest. Verify the artifact. Stop and obtain explicit user consent before installing or changing files.你的智能体仍应展示其计划,并按安全策略请求必要确认。
Agent 可读资源
当 AI Agent、爬虫或脚本需要干净上下文,而不是读取完整页面时,请使用这些链接。
测试它
正在使用“Hooks Automation”。 我需要为一个小型 TypeScript 服务配置钩子。
预期结果:
一个简洁的设置计划,涵盖编辑前验证、编辑后格式化、测试执行和会话结束摘要。
正在使用“Hooks Automation”。 我的团队想要多智能体记忆协调。
预期结果:
一个工作流,用于分配记忆命名空间、存储任务决策、恢复会话上下文并导出摘要指标。
正在使用“Hooks Automation”。 在生产环境使用前检查这个钩子计划。
预期结果:
一份风险审查,重点指出 shell 命令使用、敏感文件处理、超时设置和所需的手动批准。
安全审计
高风险Static findings largely match Markdown code formatting and documented CLI examples rather than executable files. However, the supplied automatic hook configurations interpolate tool-controlled values into shell commands without safe argument handling, creating a high-confidence command-injection risk. The skill also recommends a globally installed floating alpha dependency.
已确认安全问题 (2)
风险因素
⚙️ 外部命令 (50)
📁 文件系统访问 (1)
分享与引用此报告
分享版本化评估报告、中性徽章、嵌入卡片和引用。Skillstore 只报告证据,不判断该 Skill 是否安全。
复制报告链接
https://skillstore.io/skills/ruvnet-hooks-automation/audits/10?utm_source=security_passport&utm_medium=share&utm_campaign=versioned_reportMarkdown 徽章
[](https://skillstore.io/skills/ruvnet-hooks-automation?utm_source=security_passport_badge)HTML 徽章
<a href="https://skillstore.io/skills/ruvnet-hooks-automation?utm_source=security_passport_badge"><img src="https://skillstore.io/badges/skills/ruvnet-hooks-automation/security.svg" alt="Skillstore security assessment" loading="lazy"></a>嵌入卡片
<iframe src="https://skillstore.io/embed/skills/ruvnet-hooks-automation.html" title="Skillstore Security Assessment" sandbox="allow-popups allow-popups-to-escape-sandbox" loading="lazy" referrerpolicy="no-referrer" width="420" height="180"></iframe>学术引用 (APA · BibTeX · CFF)
APA 引用
ruvnet. (2026). Hooks Automation security audit report (audit version 10) [Author version unspecified]. Skillstore. https://skillstore.io/skills/ruvnet-hooks-automation/audits/10BibTeX 引用
@techreport{ruvnet-ruvnet-hooks-automation-2026,
author = {ruvnet},
title = {Hooks Automation security audit report (audit version 10)},
institution = {Skillstore},
year = {2026},
number = {10},
url = {https://skillstore.io/skills/ruvnet-hooks-automation/audits/10},
note = {Author version unspecified}
}CITATION.cff
cff-version: 1.2.0
message: "If you use this Skill, cite its author and this versioned security audit report."
title: "Hooks Automation security audit report (audit version 10)"
version: "unspecified"
type: report
authors:
- name: "ruvnet"
date-released: "2026-07-20"
url: "https://skillstore.io/skills/ruvnet-hooks-automation/audits/10"
identifiers:
- type: other
value: "skillstore:ruvnet-hooks-automation:audit:10"
description: "Skillstore immutable audit report identifier"
比较变体
2 个可安装变体每位作者的技能都保持为独立的可安装项。推荐变体按 Skillstore 证据排序。
为什么此变体排名第一
Skillstore 评分
评分依据 证据置信度: 中你能构建什么
标准化项目钩子
为一个代码库中的格式化、验证和会话状态创建可重复使用的钩子计划。
协调智能体工作流
使用任务和记忆钩子,让多智能体 Claude Code 工作在跨会话中保持一致。
添加 Git 质量门禁
调整文档中的 Git 钩子模式,用于预提交检查、提交后指标和推送验证。
试试这些提示
帮我为这个代码库规划基础 Claude Code 钩子。重点关注编辑前验证、编辑后格式化和会话摘要。
审查我的 Claude Code 钩子设置,检查安全性、缺失的超时设置和不必要的命令执行。建议一个更安全的配置。
设计一个钩子工作流,用记忆键和会话恢复步骤协调后端、前端和测试智能体。
为提交和推送创建一个加固的 Git 钩子自动化计划。包括命令审查、密钥保护和失败处理。
最佳实践
- 在自动钩子中启用每个 shell 命令前都要进行审查。
- 为高风险操作添加超时、手动批准和明确的失败行为。
- 按项目、会话、任务和智能体角色组织记忆键。
避免
- 不要在 shell 命令中运行未经转义的模板化工具参数。
- 不要默认允许钩子复制或记录包含密钥的环境文件。
- 不要在一次性代码库中测试之前启用范围过广的自动钩子。