← Back to Skills Marketplace
yinjin

AI Editor Rules

by 如辰 · GitHub ↗ · v1.0.0
cross-platform ✓ Security Clean
391
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install ai-editor-rules
Description
AI代码编辑器规则模板集合 - 为Cursor、Windsurf、Claude Code、Cline等AI编辑器提供项目规则配置。适用于需要配置AI编码助手规则的开发者,包含全栈Web、移动端、Vue3+SpringBoot等技术栈模板。
README (SKILL.md)

AI Editor Rules 技能

为各种 AI 代码编辑器提供项目规则配置模板。

快速开始

复制规则文件到项目

根据你使用的编辑器,复制对应文件到项目根目录:

your-project/
├── .cursorrules           # Cursor
├── .windsurfrules         # Windsurf
├── .claude/CLAUDE.md      # Claude Code
└── AGENTS.md

# 通用 使用 crossrule 转换(推荐)

# 安装 crossrule
npm install -g crossrule

# 初始化项目
crossrule init

# 转换格式
crossrule convert --from cursor --to windsurf

支持的编辑器

编辑器 规则文件 位置
Cursor .cursorrules 项目根目录
Claude Code CLAUDE.md .claude/ 目录
Windsurf .windsurfrules 项目根目录
Cline .clinerules 项目根目录
OpenCode AGENTS.md 项目根目录

包含的模板

1. 全栈 Web (React + Node.js)

  • 技术栈:React 19, TypeScript, Node.js, PostgreSQL, Prisma
  • 适合:Web 应用开发

2. 移动端 (React Native)

  • 技术栈:React Native, Expo, TypeScript, Zustand
  • 适合:iOS/Android 应用

3. Vue3 + SpringBoot3 + MySQL8

  • 技术栈:Vue 3, TypeScript, Vite, Spring Boot, MySQL
  • 适合:Java 全栈开发

4. Python 后端 (FastAPI)

  • 技术栈:Python 3.12, FastAPI, SQLAlchemy, PostgreSQL
  • 适合:API 开发

自定义模板

复制模板后,根据你的项目修改:

  1. 技术栈 - 更新框架和库版本
  2. 代码风格 - 调整命名规范
  3. 项目结构 - 适配你的目录
  4. 约束规则 - 添加特定领域规则

规则类型说明

Always (始终生效)

应用于所有代码:

alwaysApply: true

Pattern (模式匹配)

特定文件类型:

globs:
  - "*.tsx"
  - "*.jsx"

Manual (手动触发)

需要明确调用:

trigger: manual

验证规则

使用对应编辑器的命令验证:

# Cursor
cursor --rule-check

# Claude Code
claude --verify-rules

更新日志

  • v1.0.0: 初始版本,包含 4 种技术栈模板
Usage Guidance
This skill appears to do what it says (editor rule templates). Before installing or following its commands: 1) Verify the external CLI it suggests (crossrule) — check the npm package name, author, and repository before running `npm install -g` (or prefer a local/devDependency install). 2) Inspect the template files you copy into projects to ensure they don't accidentally include secrets or unwanted project-specific settings. 3) Be cautious with AGENTS.md guidance to 'write memory to a file' — avoid persisting sensitive data (API keys, personal info). 4) If you need higher assurance, ask for the skill's source or homepage or run the suggested tools in a sandbox/container first.
Capability Analysis
Type: OpenClaw Skill Name: ai-editor-rules Version: 1.0.0 The skill bundle provides configuration templates and best practices for AI code editors and agents. The `SKILL.md` instructs users to copy rule files and optionally install `crossrule` via `npm install -g`. While installing global npm packages can be a supply chain risk, this is a standard developer action for a stated purpose and not indicative of malicious intent within the skill itself. Crucially, the `AGENTS.md` file explicitly outlines safety rules for AI agents, including prohibitions against data exfiltration and unauthorized publishing, and promotes secure coding practices in the other rule files. There is no evidence of intentional harmful behavior, obfuscation, or prompt injection designed to subvert the agent for malicious purposes.
Capability Assessment
Purpose & Capability
The skill name/description (AI editor rule templates) aligns with the provided files (Cursor/Windsurf/Claude templates and AGENTS.md) and the runtime instructions (copy templates into project, optionally convert with a tool). Nothing declared in the skill (no env vars, no binaries required) is unexpected for this purpose.
Instruction Scope
SKILL.md stays on-topic (copying rule files, explains formats, shows example validation commands). It does instruct installing and running external CLIs (npm -g crossrule, and commands like `cursor --rule-check` / `claude --verify-rules`) — these are reasonable for the task but are external operations that will run code outside the skill. The included AGENTS.md directs agents to write memory to files, which is a behavioral recommendation that can cause persistent storage of data if followed.
Install Mechanism
There is no formal install spec (skill is instruction-only). The README recommends `npm install -g crossrule` (an npm global install). Installing a public npm package is common for this use-case but carries the usual registry/package trust considerations (verify package name/author and version before global install).
Credentials
The skill declares no required environment variables, credentials, or config paths. Templates and guidance mention using environment variables (e.g., process.env) as a best practice, which is appropriate for project rules but the skill itself does not request secrets.
Persistence & Privilege
The skill is not always-enabled and does not request elevated platform privileges. However, the included AGENTS.md advocates writing memory to files and keeping AGENTS.md in workspace; following that could lead to persistent storage of agent data (including anything an agent decides to 'remember'). The skill itself does not enforce persistence, but it encourages practices that create persisted files.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install ai-editor-rules
  3. After installation, invoke the skill by name or use /ai-editor-rules
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
ai-editor-rules v1.0.0 - 首次发布,提供 AI 代码编辑器规则模板集合 - 支持 Cursor、Windsurf、Claude Code、Cline、OpenCode 等主流 AI 编辑器 - 包含全栈 Web、移动端、Vue3+SpringBoot、Python 后端等主流技术栈模板 - 提供规则类型、用法说明及自定义指导
Metadata
Slug ai-editor-rules
Version 1.0.0
License
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is AI Editor Rules?

AI代码编辑器规则模板集合 - 为Cursor、Windsurf、Claude Code、Cline等AI编辑器提供项目规则配置。适用于需要配置AI编码助手规则的开发者,包含全栈Web、移动端、Vue3+SpringBoot等技术栈模板。 It is an AI Agent Skill for Claude Code / OpenClaw, with 391 downloads so far.

How do I install AI Editor Rules?

Run "/install ai-editor-rules" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is AI Editor Rules free?

Yes, AI Editor Rules is completely free (open-source). You can download, install and use it at no cost.

Which platforms does AI Editor Rules support?

AI Editor Rules is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created AI Editor Rules?

It is built and maintained by 如辰 (@yinjin); the current version is v1.0.0.

💬 Comments