
Product
Introducing Repository Access Permissions and Custom Roles
Socket now supports Custom Roles and Repository Access Permissions so organizations can control who can access specific repositories and actions.
A CLI tool to easily sync all of your favorite AI assistant instruction files from a single source. Inspired by [rulesync](https://github.com/jpcaparas/rulesync).
A CLI tool to easily sync all of your favorite AI assistant instruction files from a single source. Inspired by rulesync.
CLAUDE.md.cursorrules.github/copilot-instructions.mdGEMINI.mdAGENTS.md.clinerules/project.md.junie/guidelines.md.windsurfrules.trae/rules.md.lingma/rules.kiro/steering.codebuddy/rules/{name}.mdbun install -g onlyrules
bun install onlyrules
The quickest way to get started with OnlyRules is to initialize a new project:
npx rulesync init
This will create a basic configuration and template files in your current directory. After initialization, you can:
.augment/rules directorygenerate commandFor more advanced usage, see the sections below.
From a local file:
onlyrules generate -f ./rules.md
From a URL:
onlyrules generate -f "https://onlyrules.codes/api/rules/raw?id=cmd9nww9z0007l5040oegtmb1"
Specify an output directory:
onlyrules generate -f ./rules.md -o ./output
Force overwrite existing files:
onlyrules generate -f ./rules.md --force
Generate rules for specific AI assistants only:
onlyrules generate -f ./rules.md --target cursor,windsurf
onlyrules generate -f ./rules.md --target kiro,cursor,codebuddy
Available targets include: cursor, copilot, cline, claude, gemini, roo, kiro, codebuddy, windsurf, agents, junie, trae, augment, lingma
onlyrules add -f ./rules-new.mdc
The add command appends new rules to the rulesync.mdc file. When appending:
---)Options:
-f, --file <path>: Source file or URL containing rules to append (required)-o, --output <path>: Target file to append to (default: ./rulesync.mdc)Examples:
# Append from local file
onlyrules add -f ./new-rules.mdc
# Append from remote URL
onlyrules add -f https://example.com/rules.mdc
# Append to custom target file
onlyrules add -f ./rules.mdc -o ./custom-rules.mdc
List available templates:
onlyrules templates
View a specific template:
onlyrules template basic
Create a new rules file from a template:
onlyrules init development -o ./my-rules.md
OnlyRules comes with several built-in templates to help you get started:
basic: Simple rules for general AI assistant behaviordevelopment: Rules focused on software development practicesmulti-step: A structured approach to creating comprehensive rulesOnlyRules now supports Kiro AI's steering file system. Kiro uses markdown files in .kiro/steering/ to provide persistent project knowledge.
Use the Kiro example template to get started:
onlyrules init kiro-example
This creates a comprehensive set of steering files demonstrating:
When generating rules for Kiro, OnlyRules automatically configures appropriate inclusion modes:
# Clone the repository
git clone https://github.com/yourusername/onlyrules.git
cd onlyrules
# Install dependencies
bun install
# Build the project
bun run build
# Run tests
bun run test
This project uses Vitest for testing and follows Test-Driven Development (TDD) principles:
# Run tests once
bun run test
# Run tests in watch mode
bun run test:watch
# Run tests with coverage
bun run test:coverage
This project uses Biome for linting and formatting:
# Format code
bun run format
# Lint code
bun run lint
# Fix linting issues
bun run lint:fix
MIT
FAQs
A CLI tool to easily sync all of your favorite AI assistant instruction files from a single source. Inspired by [rulesync](https://github.com/jpcaparas/rulesync).
The npm package onlyrules receives a total of 21 weekly downloads. As such, onlyrules popularity was classified as not popular.
We found that onlyrules demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Socket now supports Custom Roles and Repository Access Permissions so organizations can control who can access specific repositories and actions.

Product
Socket MCP now lets AI assistants review org alerts, investigate threats using the Socket threat feed, and inspect package files in addition to dependency scoring.

Product
Socket Firewall blocks malicious VS Code and Open VSX extensions before install, protecting developers from compromised editor marketplaces.