https://github.com/alexeykarnachev/py-codecompanion-workspace
CLI tool for managing CodeCompanion workspaces - creates and compiles standardized project structures with YAML configurations to JSON workspace definitions.
https://github.com/alexeykarnachev/py-codecompanion-workspace
cli code-companion developer-tools project-scaffolding pydantic pytho typer workspace-management yaml
Last synced: 2 months ago
JSON representation
CLI tool for managing CodeCompanion workspaces - creates and compiles standardized project structures with YAML configurations to JSON workspace definitions.
- Host: GitHub
- URL: https://github.com/alexeykarnachev/py-codecompanion-workspace
- Owner: alexeykarnachev
- Created: 2025-02-04T18:23:36.000Z (4 months ago)
- Default Branch: master
- Last Pushed: 2025-02-04T18:57:53.000Z (4 months ago)
- Last Synced: 2025-02-04T19:40:14.311Z (4 months ago)
- Topics: cli, code-companion, developer-tools, project-scaffolding, pydantic, pytho, typer, workspace-management, yaml
- Language: Python
- Homepage:
- Size: 49.8 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# cc-workspace
A CLI tool to generate workspace files for [CodeCompanion.nvim](https://github.com/olimorris/codecompanion.nvim) ✨
## Quick Start
### Global Installation
```bash
uv pip install --system git+https://github.com/alexeykarnachev/py-codecompanion-workspace
```### Initialize in Existing Project
```bash
cd my-project
ccw init .
```### Create New Python Project
```bash
ccw init my-new-project
```## What You Get
For any project:
- `.cc/codecompanion.yaml` - Workspace configuration
- `.cc/data/` - Internal cc files (e.g `CONVENTIONS.md`)
- `codecompanion-workspace.json` - Compiled configurationFor new Python projects:
- Basic Python project structure:
- Package directory with `__init__.py` and `main.py`
- Tests directory with initial test
- Scripts directory with quality checks
- Configuration files:
- `pyproject.toml` with modern tools setup
- Type hints and quality checks configuration
- Version management
- Documentation:
- README.md with quick start guide
- CHANGELOG.md following Keep a Changelog format
- .gitignore with comprehensive Python patterns
- Git repository:
- Initialized with initial commit
- Using your Git configuration## Usage
### Basic Commands
```bash
# Initialize in current directory
ccw init .# Create new project
ccw init my-project# Force initialize in existing directory
ccw init my-project --force# Use specific template
ccw init my-project --template default# Update configuration after changes
ccw compile-config .cc/codecompanion.yaml
```### Getting Help
```bash
ccw --help
ccw init --help
ccw compile-config --help
```## Configuration
The workspace configuration is stored in `.cc/codecompanion.yaml`. Here's an example:
```yaml
name: "my-project"
description: "Project description"
system_prompt: "Custom system prompt for LLM interactions"
ignore:
enabled: true
patterns:
default: ["*.lock", ".env"]
additional: ["custom.ignore"]
categories: ["default"]
groups:
- name: "Core"
description: "Core project files"
files:
- path: "{package_name}/**/*.py"
description: "Source files"
kind: "pattern"
- path: "tests/**/*.py"
description: "Test files"
kind: "pattern"
```Key features:
- Pattern-based file discovery with `**/*` glob support
- Customizable ignore patterns
- File grouping for better organization
- Custom system prompts per groupAfter modifying the config:
1. Run `ccw compile-config .cc/codecompanion.yaml`
2. Use the generated `codecompanion-workspace.json` in Neovim## License
[MIT](LICENSE)