AI Docs CLI is a Go-based command-line tool designed to streamline the management of AI-generated memory files. By creating an isolated Git branch, it simplifies workflows for multiple AI agents, while automatically managing .gitignore updates and providing flexible push/pull commands.
AI Docs CLI is a powerful command-line interface tool crafted in Go that streamlines the management of AI-generated memory files, such as GEMINI.md, CLAUDE.md, and other related files. This tool allows users to easily manage their AI memory on a dedicated Git branch with an intuitive workflow designed for seamless file isolation and synchronization.
.gitignore to prevent unnecessary files in the repository.To set up AI Docs, the following command initializes the configuration and prepares the dedicated Git branch:
ai-docs init [--config path/to/.ai-docs.config.yml] [--force] [--dry-run] [-v]
This command performs several key actions, such as creating an orphan branch, copying AI memory files, committing and pushing changes, and updating .gitignore. It ensures that the main branch remains uncluttered by AI-specific files.
To sync local AI documents to the dedicated branch, use the command:
ai-docs push [--config path/to/config.yml] [--dry-run] [-v]
This commits any local updates and pushes them to the remote repository, allowing for easy collaboration and backup of AI documents.
To retrieve the latest updates from the AI docs branch, the command is:
ai-docs pull [--config path/to/config.yml] [--overwrite] [--dry-run] [-v]
This pulls the most recent changes, with an optional overwrite to replace existing local files.
For cleaning up the worktree and branch once done, the following command is available:
ai-docs clean [--config path/to/config.yml] [--force] [--dry-run] [-v]
Setting up a configuration file (.ai-docs.config.yml) in your project root allows customization of various parameters to suit specific workflows:
userName: "" # fallback when git config user.name is empty
mainBranchName: "main"
docBranchNameTemplate: "@ai-docs/{userName}"
docWorktreeDir: ".ai-docs"
aIAgentMemoryContextPath:
Cline: "memory-bank"
Claude: "CLAUDE.md"
Gemini: "GEMINI.md"
Cursor: ".cursor/rules"
ignorePatterns:
- "/memory-bank/"
- "CLAUDE.md"
- "GEMINI.md"
- "/.cursor/rules"
AI Docs CLI is an essential tool for developers and data scientists looking to maintain organized and isolated AI memory files while leveraging Git's powerful version control capabilities.
No comments yet.
Sign in to be the first to comment.