Codio is both an executable binary that can be run, and a library that can be used in Rust programs.
Installing the command-line executable
Assuming you have Rust/Cargo installed , run this command in a terminal:
cargo install codio
It will make the codio command available in your PATH if you've allowed the PATH to be modified when installing Rust . cargo uninstall codio uninstalls.
Adding codio library as a dependency
Run this command in a terminal, in your project's directory:
cargo add codio
To add it manually, edit your project's Cargo.toml file and add to the [dependencies] section:
codio = "0.1.1"
The codio library will be automatically available globally.
Read the codio library documentation .
Back to the crate overview .
Readme
Codio (Production)
Codio is an internal CLI for automated Git workflows with local Ollama-powered Conventional Commit generation.
This README is for production/internal usage only.
Developer / Maintainer
Purpose
Codio standardizes team commits by:
generating validated Conventional Commit messages from real diffs
enforcing commit message structure before commit
supporting fully automated local workflows (add -> gen -> push )
Prerequisites
Git repository (run inside repo root or any subdirectory)
Local Ollama daemon (http://localhost:11434 )
Installed local model (default: qwen2. 5 - coder )
Configured Git identity (user. name , user. email )
Install / Update
From this folder:
./install.sh
Update after changes:
./install.sh -- force
Uninstall:
./uninstall.sh
Operational Commands
Stage files:
codio add .
# or
codio add src/main.rs README.md
Generate commit message from staged diff and commit:
codio gen
Generate + edit message before commit:
codio gen -- edit
Push current branch:
codio push
Full automation (stage all + generate + commit + push):
codio git
Diagnostics / runtime health:
codio status
Flags
Global flags (available for all commands):
--model < name> : Ollama model (default: qwen2. 5 - coder )
--scope < scope| auto> : explicit or inferred scope
--staged-only : fail when nothing staged
--max-chars < n> : diff truncation budget (300..=200000, default 12000)
--dry-run : print final message, skip commit/push actions
--no-body : subject only
--verbose : verbose logs
--no-progress : disable spinner/progress UI
Safety and Validation
Codio includes production safety controls:
redacts sensitive diff lines before prompting Ollama
omits sensitive file content (. env, key/secret-like files)
validates commit format before commit:
type ( scope) : summary
allowed types: feat , fix , docs , refactor , perf , test , chore , build , ci
subject length <= 72 chars
body structure with blank line + bullet lines
auto-coerces non-conforming model output into valid Conventional format
Recommended Team Flow
codio status to verify environment/model/repo state.
codio git for normal feature work.
Use codio gen - - edit when you need manual wording control.
Use --dry-run in sensitive branches before final commit.
Troubleshooting
codio status should be your first check.
Common issues:
Ollama unreachable:
Start service: ollama serve
Model missing:
Install model: ollama pull qwen2. 5 - coder
Push failed / upstream missing:
git push - u origin < branch>
No staged changes for codio gen :
Stage first via codio add ... or use codio git