agentsclimarketplace

Export rules

Skill claude-hangar/claude-hangar/core/skills/export-rules

Production-grade configuration management for Claude Code. Hooks, agents, skills, multi-project orchestration.

Install
npx -y skills add claude-hangar/claude-hangar --skill export-rules

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 1 stars1 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Export Claude Hangar skills and rules to other AI coding tool formats. Use when: "export rules", "cursor rules", "windsurf rules", "export-rules", "convert to mdc".

SKILL.md

3.8 KB, as published. Nobody here has run it

/export-rules — Cross-IDE Rule Export

Convert Claude Hangar skills and rules into formats compatible with other AI coding tools.

Supported Formats

TargetFormatOutput Location
Cursor.cursor/rules/*.mdcOne .mdc file per rule
Windsurf.windsurfrulesSingle rules file
GitHub Copilot.github/copilot-instructions.mdSingle instructions file
Cline.clinerulesSingle rules file

Instructions

Step 1: Determine Target

From $ARGUMENTS:

  • cursor → Generate Cursor .mdc rules
  • windsurf → Generate Windsurf rules file
  • cline → Generate Cline rules file
  • copilot → Generate Copilot instructions
  • all → Generate all formats
  • No argument → Ask which format(s) to generate

Step 2: Gather Source Material

Read these Hangar sources (in order of importance):

  1. Project CLAUDE.md (if exists in cwd)
  2. ~/.claude/rules/common/*.md — Governance rules
  3. ~/.claude/rules/{lang}/*.md — Language-specific rules (detect from project)
  4. Active skills in ~/.claude/skills/*/SKILL.md — Extract key patterns

Step 3: Generate — Cursor (.mdc)

Create .cursor/rules/ directory and generate one .mdc file per rule category:

---
description: {{Rule description for Cursor context matching}}
globs: {{file patterns this rule applies to, e.g. "**/*.ts"}}
alwaysApply: {{true for universal rules, false for file-specific}}
---

{{Rule content — concise, actionable instructions}}

Mapping:

  • rules/common/coding-style.md.cursor/rules/coding-style.mdc (alwaysApply: true)
  • rules/common/security.md.cursor/rules/security.mdc (alwaysApply: true)
  • rules/typescript/patterns.md.cursor/rules/typescript.mdc (globs: **/*.ts,**/*.tsx)
  • rules/python/patterns.md.cursor/rules/python.mdc (globs: **/*.py)

Step 4: Generate — Windsurf

Create a single .windsurfrules file at the project root:

# Project Rules

## Code Quality
{{Extracted from coding-style.md}}

## Security
{{Extracted from security.md}}

## Language-Specific
{{Extracted from detected language rules}}

## Workflow
{{Extracted from development-workflow.md}}

Step 5: Generate — Cline

Create a single .clinerules file at the project root:

# Project Rules

## Code Quality
{{Extracted from coding-style.md}}

## Security
{{Extracted from security.md}}

## Language-Specific
{{Extracted from detected language rules}}

## Workflow
{{Extracted from development-workflow.md}}

Note: Cline uses a flat rules file similar to Windsurf. The format is identical but the filename differs (.clinerules vs .windsurfrules).

Step 6: Generate — GitHub Copilot

Create .github/copilot-instructions.md:

# Copilot Instructions

## Project Context
{{From CLAUDE.md}}

## Code Standards
{{From coding-style.md, testing.md}}

## Security Requirements
{{From security.md}}

Step 7: Report

## Export Complete

| Format | Files | Location |
|--------|-------|----------|
| Cursor | N rules | .cursor/rules/*.mdc |
| Windsurf | 1 file | .windsurfrules |
| Cline | 1 file | .clinerules |
| Copilot | 1 file | .github/copilot-instructions.md |

Total rules exported: N

Rules

  • Preserve the intent and strictness of original rules
  • Adapt format but not content — don't weaken rules for compatibility
  • Skip Hangar-specific references (hook-gate, skills, statusline)
  • Include only rules relevant to the detected project stack
  • Don't export hooks (these are Claude Code-specific)

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.