mirror of
https://github.com/RooVetGit/Roo-Code.git
synced 2026-10-09 03:17:58 +00:00
- Move all documentation files from standalone repo to apps/docs - Create @roo-code/docs package with workspace dependencies - Update docusaurus.config.ts editUrl to point to apps/docs path - Fix @roo-code/types package.json to export built files instead of source - Add missing dependencies (@docusaurus/plugin-content-docs, @docusaurus/theme-common, @easyops-cn/autocomplete.js) - Update turbo.json to include docs build outputs - Add comprehensive README with setup instructions - Add .gitignore to exclude build artifacts - Fix TypeScript error with inert attribute This migration consolidates the docs into the main repository for better integration and streamlined deployment via Vercel. Note: GitHub Actions workflows for deployment will be added manually due to repository permissions.
92 lines
2.5 KiB
Markdown
92 lines
2.5 KiB
Markdown
# Roo Code Documentation
|
|
|
|
This directory contains the official documentation site for Roo Code, built with [Docusaurus](https://docusaurus.io/).
|
|
|
|
## Development
|
|
|
|
```bash
|
|
# From the monorepo root
|
|
pnpm install
|
|
|
|
# Start the development server
|
|
pnpm --filter @roo-code/docs start
|
|
|
|
# Build the site
|
|
pnpm --filter @roo-code/docs build
|
|
|
|
# Serve the built site locally
|
|
pnpm --filter @roo-code/docs serve
|
|
```
|
|
|
|
## Environment Variables
|
|
|
|
Create a `.env` file based on `.env.example`:
|
|
|
|
- `POSTHOG_API_KEY`: Analytics key for PostHog (optional)
|
|
- `INTERCOM_APP_ID`: Intercom widget ID (optional)
|
|
|
|
## Vercel Deployment Setup
|
|
|
|
The docs are deployed to Vercel automatically on push to `main`. To set up:
|
|
|
|
### Required Secrets
|
|
|
|
Add these secrets to the GitHub repository settings:
|
|
|
|
1. **VERCEL_TOKEN**: Personal Access Token from Vercel
|
|
|
|
- Go to Vercel → Settings → Tokens
|
|
- Create a new token with appropriate permissions
|
|
|
|
2. **VERCEL_ORG_ID**: Organization ID from Vercel
|
|
|
|
- Run `vercel link` in the docs directory
|
|
- Find the ID in `.vercel/project.json`
|
|
|
|
3. **VERCEL_DOCS_PROJECT_ID**: Project ID for the docs
|
|
|
|
- Same as above, from `.vercel/project.json`
|
|
|
|
4. **POSTHOG_API_KEY**: PostHog analytics key (optional)
|
|
|
|
5. **INTERCOM_APP_ID**: Intercom widget ID (optional)
|
|
|
|
### Vercel Project Configuration
|
|
|
|
In the Vercel project settings:
|
|
|
|
- **Root Directory**: `apps/docs`
|
|
- **Build Command**: `pnpm build`
|
|
- **Output Directory**: `build`
|
|
- **Install Command**: `pnpm install --frozen-lockfile`
|
|
- **Framework Preset**: Other
|
|
- **Node Version**: 20.x
|
|
|
|
### Custom Domain
|
|
|
|
Configure the custom domain `docs.roocode.com` in Vercel project settings.
|
|
|
|
## Structure
|
|
|
|
- `docs/`: Markdown documentation files
|
|
- `src/`: Custom React components and theme overrides
|
|
- `static/`: Static assets (images, etc.)
|
|
- `docusaurus.config.ts`: Main configuration file
|
|
- `sidebars.ts`: Sidebar navigation structure
|
|
|
|
## Writing Documentation
|
|
|
|
- Use absolute, extensionless paths for internal links: `/basic-usage/how-tools-work`
|
|
- Use HTML `<img>` tags for images: `<img src="/img/example.png" alt="Description" width="600" />`
|
|
- Add redirects in `docusaurus.config.ts` when moving/renaming pages
|
|
|
|
## Migration Notes
|
|
|
|
This documentation was migrated from the standalone `Roo-Code-Docs` repository into the monorepo as `apps/docs`.
|
|
|
|
Key changes:
|
|
|
|
- Package name changed to `@roo-code/docs`
|
|
- `@roo-code/types` dependency uses `workspace:^` protocol
|
|
- Edit URLs now point to `apps/docs/` path in the Roo-Code repository
|
|
- Deployment moved from standalone repo to monorepo workflows
|