Back to feed
Dev.to
Dev.to
7/12/2026
Stop Symlinking Your Cursor and Claude Code Rules — Generate Them Instead

Stop Symlinking Your Cursor and Claude Code Rules — Generate Them Instead

Short summary

Cursor and Claude Code use incompatible rule file formats—different extensions (.mdc vs .md) and frontmatter keys (globs vs paths)—so symlinking one directory silently breaks both tools. The solution is to treat Claude Code's .md files as the source of truth and generate Cursor's .mdc files with a zero-dependency Node script. The generator mechanically maps paths lists to globs strings and sets alwaysApply accordingly.

  • Symlinking .cursor/rules and .claude/rules fails silently due to extension and frontmatter incompatibilities
  • Claude Code .md files serve as source of truth; a Node script generates Cursor .mdc files
  • Mapping is mechanical: paths list → globs string, absent paths → alwaysApply true

Generated with AI, which can make mistakes.

Is this a good recommendation for you?

Comments

Failed to load comments. Please try again.

Explore more