Package Exports
- byterover-cli
- byterover-cli/dist/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (byterover-cli) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
ByteRover CLI
Command-line interface for ByteRover, enabling seamless team/space management, authentication, and space's memory operations directly from your terminal.
Important
Starting with version 0.2.0, the ByteRover CLI command has been renamed from br to brv to avoid conflicts with broot, another popular CLI tool that also uses the br command.
This is a breaking change that requires action from existing users.
Please check the migration guide here.
Table of Contents
- Installation
- Quick Start
- What is Context Tree?
- Essential Commands
- Authentication
- Configuration
- Getting Help
Installation
Requirements
- Node.js: >= 20.0.0
- Operating System:
- macOS
- Windows
- Linux
- Currently this CLI uses
libsecret. Depending on your distribution, you will need to run the following command:- Debian/Ubuntu:
sudo apt-get install libsecret-1-dev - Red Hat-based:
sudo yum install libsecret-devel - Arch Linux:
sudo pacman -S libsecret
- Debian/Ubuntu:
- Currently this CLI uses
Install globally via npm
npm install -g byterover-cliVerify installation
brv --versionQuick Start
Visit ByteRover's Beta Docs for more information.
Get started with ByteRover CLI in three simple steps:
1. Authenticate
brv loginThis opens your browser to complete OAuth authentication. Your credentials are securely stored in the system keychain.
2. Initialize a project
cd to/your/project
brv initSelect a space from your available spaces and configure your project.
3. Start using ByteRover
You're ready to use ByteRover commands in your project!
What is Context Tree?
The Context Tree is ByteRover's structured memory system that helps you and your coding agents organize, store, and retrieve project knowledge efficiently.
Why Use Context Tree?
- Organized Knowledge: Structure your project knowledge by domain and topic
- Easy Retrieval: Find relevant context quickly when you need it
- Persistent Memory: Maintain project-specific knowledge across sessions
- Agent-Friendly: Works seamlessly with coding agents like Claude Code, Cursor, and others
- Version Control: Push and sync your context to ByteRover's cloud storage
How It Works
The context tree organizes knowledge into:
- Domains: High-level categories (e.g., Architecture, API, Frontend)
- Topics: Specific subjects within domains (e.g., Authentication, Components)
- Context Files: Markdown files containing your actual knowledge
For comprehensive instructions for coding agents, check the generated rule files after running brv gen-rules.
Essential Commands
Authentication
# Log in to ByteRover
brv login
# Log out and clear credentials
brv logout
# Check your authentication and project status
brv statusProject Setup
# Initialize project with ByteRover
brv init
# List available spaces
brv space list
# Switch to a different space or team
brv space switchMemory Operations
# Add content to context tree (interactive or autonomous)
brv curate
brv curate "User authentication uses JWT tokens"
# Push your context tree to ByteRover's memory storage
brv push
# Pull context tree from ByteRover cloud
brv pull
# Query the context tree
brv query "How is authentication implemented?"
# Reset context tree to default state
brv clearFor Coding Agents
# Generate agent rules (sets up context tree workflow for your coding agent)
brv gen-rulesAuthentication
ByteRover CLI uses OAuth 2.0 with PKCE (Proof Key for Code Exchange) for secure authentication.
How it works
- Run
brv loginto start authentication - Your browser opens to the ByteRover authorization page
- After successful login, tokens are securely stored in your system keychain
- All subsequent commands automatically use your stored credentials
Security features
- PKCE flow: Prevents authorization code interception attacks
- System keychain: Tokens stored in macOS Keychain
- Session tracking: Each session includes a session key for request tracking
- Auto-refresh: Refresh tokens enable seamless credential renewal
Configuration
Project Configuration
When you run brv init, a configuration file is created at .brv/config.json in your project directory containing:
- Space ID: The ByteRover workspace/space associated with this project
- User information: Your user ID and email
- Project settings: Project-specific configuration
Context Tree Structure
The context tree is stored in .brv/context-tree/:
.brv/context-tree/
├── Architecture/
│ ├── System Design/
│ │ └── context.md
│ └── Database Schema/
│ └── context.md
├── API/
│ ├── Authentication/
│ │ └── context.md
│ └── Endpoints/
│ └── context.md
└── Frontend/
├── Components/
│ └── context.md
└── State Management/
└── context.mdNote: When you run brv push, your context tree is uploaded to ByteRover's memory storage for version control and team collaboration.
Getting Help
Command Help
# Get general help
brv --help
# Get help for a specific command
brv login --help
brv init --help
brv push --help
brv pull --help
brv query --help
brv clear --helpSupport
If you encounter issues or have questions:
- Check the command help:
brv [command] --help - Review your status:
brv status - Contact ByteRover support
Copyright (c) ByteRover