feat(aiCommitExt): add user-suggested commit-message refinement

This commit is contained in:
2026-04-15 12:01:40 +02:00
parent 4fc21100a9
commit a7f07dbeef
4 changed files with 52 additions and 4 deletions
+22
View File
@@ -0,0 +1,22 @@
# AGENTS.md
## Build & Run
- **Compile**: `npm run compile` (or `tsc -p ./`)
- **Watch**: `npm run watch`
- **Package extension**: `npm run build` → produces `.vsix` file
- **Test**: Press F5 to launch extension in debug mode
## Project Structure
- `src/extension.ts` - Extension entry point, registers `aiCommitExt.generate` command
- `src/opencodeService.ts` - Spawns `opencode run` CLI, parses output for commit message
- `src/gitService.ts` - Uses VS Code Git extension API to get diffs and repo root
## Key Details
- Output compiled to `out/` directory
- Extension activates only on command invocation (not on startup)
- OpenCode CLI is required on PATH; checked via `which opencode`
- Generated message written to SCM input box via `repository.inputBox.value`
- Timeout: 120 seconds for OpenCode response