CLI for the mydotmd.io AI rule registry — fetch and share .md instruction files.
Project description
dotmd
The open .md registry CLI
Fetch and share the AI instruction files that power your coding assistants.
dotmd is a command-line tool for the mydotmd.io registry — like Docker Hub, but for .md instruction files. Browse, search, and pull the rules that configure AI coding assistants like Cursor, Claude, Windsurf, Copilot, and more.
Table of Contents
Install
Requires Python 3.8+
pip install dotmd
Verify the install:
dotmd --version
Quick Start
# Browse what's available
dotmd list
# Search by keyword
dotmd search react typescript
# Fetch a rule into your project
dotmd get dotmd/react-best-practices
# See where it was written
dotmd info
Commands
dotmd get
Fetch a rule from the registry and write it to the correct local instruction file for your AI tool.
# Full slug: <username>/<title>
dotmd get dotmd/react-best-practices
# Bare title — auto-resolved when only one match exists
dotmd get react-best-practices
# Explicit username with bare title
dotmd get react-best-practices --username dotmd
# Preview destination without writing (dry run)
dotmd get dotmd/react-best-practices --dry-run
# Write to a custom path
dotmd get dotmd/react-best-practices --output .cursorrules
# Overwrite an existing file
dotmd get dotmd/react-best-practices --force
# Suppress all output (useful in scripts)
dotmd get dotmd/react-best-practices --quiet
# Machine-readable JSON output
dotmd get dotmd/react-best-practices --json
Options:
| Flag | Short | Description |
|---|---|---|
--username USER |
-u |
Registry username (use with bare title) |
--output PATH |
-o |
Write to a specific path instead of the default |
--force |
-f |
Overwrite destination if it already exists |
--dry-run |
Preview destination without writing | |
--quiet |
-q |
Suppress non-error output |
--json |
Emit JSON to stdout |
dotmd search
Search the registry for rules by keyword. Matches against rule titles.
# Single keyword
dotmd search python
# Multiple keywords (AND match)
dotmd search react typescript performance
# Limit results
dotmd search react --limit 5
# JSON output for scripting
dotmd search react --json
Options:
| Flag | Short | Description |
|---|---|---|
--limit N |
-n |
Max results (default: 20, max: 100) |
--json |
Emit JSON to stdout |
dotmd list
List rules for a specific user, or all public rules in the registry.
# All public rules
dotmd list
# Rules for a specific user
dotmd list dotmd
# Limit results
dotmd list --limit 50
# JSON output
dotmd list dotmd --json
Options:
| Flag | Short | Description |
|---|---|---|
--limit N |
-n |
Max results (default: 100, max: 200) |
--json |
Emit JSON to stdout |
dotmd info
Show version, registry details, supported formats, and configuration.
dotmd info
# Skip the ASCII art banner
dotmd info --plain
# JSON output
dotmd info --json
Output File Mapping
When you run dotmd get, the rule is written to the standard location for its format type:
| Format | Written to |
|---|---|
claude.md |
CLAUDE.md |
cursorrules |
.cursorrules |
windsurfrules |
.windsurfrules |
agents.md |
AGENTS.md |
copilot |
.github/copilot-instructions.md |
gemini |
GEMINI.md |
cline |
.clinerules |
aider |
.aider.conf.yml |
continue |
.continue/config.json |
Use --output PATH to override the destination for any rule.
Configuration
dotmd works out of the box with no configuration. If your deployment requires authentication, set these environment variables:
# Supabase anon key (required for authenticated registries)
export DOTMD_SUPABASE_ANON_KEY="your-supabase-anon-key"
# Override the Supabase REST base URL (optional)
export DOTMD_SUPABASE_BASE_URL="https://your-project-ref.supabase.co/rest/v1"
# Aliases
export DOTMD_API_KEY="..." # alias for DOTMD_SUPABASE_ANON_KEY
export DOTMD_BASE_URL="..." # alias for DOTMD_SUPABASE_BASE_URL
# Disable color output (follows https://no-color.org/)
export NO_COLOR=1
Auto-discovery: If the default endpoint fails, dotmd automatically attempts to discover the current Supabase REST URL and anon key from https://mydotmd.io and retries.
LLM & Automation Usage
dotmd is designed to work cleanly in automated pipelines and as a tool for AI agents:
Pipe-friendly: When stdout is not a TTY (piped, redirected, or called by an LLM), the ASCII art banner is automatically suppressed and only plain text is emitted.
JSON output: Every command supports --json for structured, machine-readable output:
# Get a rule and parse the result
dotmd get dotmd/react-best-practices --json | jq .destination
# Search and pipe to another tool
dotmd search react --json | jq '.results[].title'
# Dry run to check destination before writing
dotmd get dotmd/react-best-practices --dry-run --json
Exit codes:
| Code | Meaning |
|---|---|
0 |
Success |
1 |
API or network error |
2 |
Usage error (bad arguments, file exists without --force, ambiguous title) |
130 |
Interrupted (Ctrl+C) |
NO_COLOR support: Set NO_COLOR=1 to disable all ANSI color codes, following the no-color.org convention.
Contributing
See CONTRIBUTING.md for development setup, testing, and pull request guidelines.
License
MIT © dotmd contributors
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file dotmd-0.1.1.tar.gz.
File metadata
- Download URL: dotmd-0.1.1.tar.gz
- Upload date:
- Size: 21.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f65ed1eb24c9f837725d37747e77e82f9c1888c44227e558d02269e571a8272d
|
|
| MD5 |
4d4d2654adf5e0f1e06845dc4b3ec6ea
|
|
| BLAKE2b-256 |
d504be2401f55d65d9c4d791dbc42551cd4561b39d25ec7044982a056f99943b
|
File details
Details for the file dotmd-0.1.1-py3-none-any.whl.
File metadata
- Download URL: dotmd-0.1.1-py3-none-any.whl
- Upload date:
- Size: 16.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
77352db19bfc08653bd96b035e5d2fb26d05af4bc844627bc1281aba3cef7cbf
|
|
| MD5 |
516999d4637406c8f3e6eea61fdb26ba
|
|
| BLAKE2b-256 |
1198089317fcf9045eb0bb1daa7c9e84dfd61b14472b44833565578c4df0d6ef
|