- Home
- MCP servers
- MCPRules - Programming Guidelines Management Server
MCPRules - Programming Guidelines Management Server
- typescript
20
GitHub Stars
typescript
Language
6 months ago
First Indexed
2 months ago
Catalog Refreshed
Documentation & install
Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.
Installation
Add the following to your MCP client configuration file.
Configuration
View docs{
"mcpServers": {
"bartwisch-mcprules": {
"command": "node",
"args": [
"/path/to/rules-server/build/index.js"
],
"env": {
"GITHUB_TOKEN": "YOUR_GITHUB_TOKEN",
"RULES_FILE_PATH": "(/path/to/your/rules.md)"
}
}
}
}You run a dedicated MCP server that organizes, serves, and enforces programming guidelines and rules across your projects. It connects with development tools to ensure consistent coding standards, supports local and GitHub-hosted rule sources, and lets you filter guidance by category for quick access during coding and reviews.
How to use
You interact with the MCP server through an MCP client to retrieve rules and lists of categories. To get guidance, request rules and choose a category to filter the results. This server exposes two primary capabilities: Get Rules, which returns applicable guidelines, and Get Categories, which lists all available rule groups.
How to install
Prerequisites: ensure you have Node.js and npm installed on your system.
# Clone the MCPRules project
git clone https://github.com/yourusername/MCPRules.git
cd MCPRules/rules-server
# Install dependencies
npm install
# Build the server
npm run build
# Set required environment variables for rule sources
export RULES_FILE_PATH=/path/to/your/rules.md
# Optional for private GitHub repositories
export GITHUB_TOKEN=your_github_token
Configuration and usage notes
Configure the MCP client integration for your development environment to point at the built server entry. The following example shows how to wire the server into a local tool that expects an executable to provide rules.
{
"mcpServers": {
"rules": {
"command": "node",
"args": ["/path/to/rules-server/build/index.js"],
"disabled": false,
"alwaysAllow": []
}
}
}
VSCode Cline extension configuration
Place this configuration in the Cline extension settings to enable the MCP Rules server integration.
{
"mcpServers": {
"rules": {
"command": "node",
"args": ["/path/to/rules-server/build/index.js"],
"disabled": false,
"alwaysAllow": []
}
}
}
Rule and category format
Rules are defined in Markdown files with a simple structure that maps a category to key-value pairs. You can expand, edit, or add new rules by placing them under the appropriate category.
Development
Development tasks include running in watch mode for automatic rebuilds and debugging when needed.
npm run watch
npm run inspector
Contributing
Contribute by forking, creating a feature branch, and submitting a pull request with your changes. This encourages a community-driven growth of the rule set.
License
This project is licensed under the MIT License.
Acknowledgments
Thanks to contributors and the MCP community for shaping reusable guidelines that improve code quality across projects.
Notes on environment variables
Two variables are commonly used to locate and access rule sources. Define them in your environment when running the server.
Example environment setup
export RULES_FILE_PATH=/path/to/your/rules.md
export GITHUB_TOKEN=your_github_token
Available tools
Get Rules
Retrieve all rules or filter by category to obtain guidance aligned with your current context.
Get Categories
List all available rule categories to understand the scope of guidance you can apply.