Skip to content

Commit fb747ab

Browse files
author
Jay Kumar
committed
Revert "refactor(gemini): migrate to coder-utils and tftpl pattern"
This reverts commit 35c03a1.
1 parent 35c03a1 commit fb747ab

6 files changed

Lines changed: 309 additions & 413 deletions

File tree

registry/coder-labs/modules/gemini/README.md

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Run [Gemini CLI](https://github.com/google-gemini/gemini-cli) in your workspace
1313
```tf
1414
module "gemini" {
1515
source = "registry.coder.com/coder-labs/gemini/coder"
16-
version = "3.1.0"
16+
version = "3.0.0"
1717
agent_id = coder_agent.main.id
1818
folder = "/home/coder/project"
1919
}
@@ -22,14 +22,15 @@ module "gemini" {
2222
## Features
2323

2424
- **Interactive AI Assistance**: Run Gemini CLI directly in your terminal for coding help
25+
- **Automated Task Execution**: Execute coding tasks automatically via AgentAPI integration
2526
- **Multiple AI Models**: Support for Gemini 2.5 Pro, Flash, and other Google AI models
2627
- **API Key Integration**: Seamless authentication with Gemini API
2728
- **MCP Server Integration**: Built-in Coder MCP server for task reporting
28-
- **Script Orchestration**: Uses coder-utils for reliable pre/install/post script ordering
29+
- **Persistent Sessions**: Maintain context across workspace sessions
2930

3031
## Prerequisites
3132

32-
- **Node.js and npm must be sourced/available before the gemini module installs**; ensure they are installed in your workspace image or via earlier provisioning steps
33+
- **Node.js and npm must be sourced/available before the gemini module installs** - ensure they are installed in your workspace image or via earlier provisioning steps
3334
- The [Coder Login](https://registry.coder.com/modules/coder/coder-login) module is required
3435

3536
## Examples
@@ -45,7 +46,7 @@ variable "gemini_api_key" {
4546
4647
module "gemini" {
4748
source = "registry.coder.com/coder-labs/gemini/coder"
48-
version = "3.1.0"
49+
version = "3.0.0"
4950
agent_id = coder_agent.main.id
5051
gemini_api_key = var.gemini_api_key
5152
folder = "/home/coder/project"
@@ -93,11 +94,12 @@ data "coder_parameter" "ai_prompt" {
9394
module "gemini" {
9495
count = data.coder_workspace.me.start_count
9596
source = "registry.coder.com/coder-labs/gemini/coder"
96-
version = "3.1.0"
97+
version = "3.0.0"
9798
agent_id = coder_agent.main.id
9899
gemini_api_key = var.gemini_api_key
99100
gemini_model = "gemini-2.5-flash"
100101
folder = "/home/coder/project"
102+
task_prompt = data.coder_parameter.ai_prompt.value
101103
enable_yolo_mode = true # Auto-approve all tool calls for automation
102104
gemini_system_prompt = <<-EOT
103105
You are a helpful coding assistant. Always explain your code changes clearly.
@@ -116,7 +118,7 @@ For enterprise users who prefer Google's Vertex AI platform:
116118
```tf
117119
module "gemini" {
118120
source = "registry.coder.com/coder-labs/gemini/coder"
119-
version = "3.1.0"
121+
version = "3.0.0"
120122
agent_id = coder_agent.main.id
121123
gemini_api_key = var.gemini_api_key
122124
folder = "/home/coder/project"
@@ -127,12 +129,13 @@ module "gemini" {
127129
## Troubleshooting
128130

129131
- If Gemini CLI is not found, ensure your API key is valid (`install_gemini` defaults to `true`)
130-
- Check logs in `~/.coder-modules/coder-labs/gemini/logs/` for install output
132+
- Check logs in `~/.gemini-module/` for install/start output
131133
- Use the `gemini_api_key` variable to avoid requiring Google sign-in
132134

133-
The module creates log files in `~/.coder-modules/coder-labs/gemini/logs/` for debugging purposes.
135+
The module creates log files in the workspace's `~/.gemini-module` directory for debugging purposes.
134136

135137
## References
136138

137139
- [Gemini CLI Documentation](https://github.com/google-gemini/gemini-cli/blob/main/docs/index.md)
140+
- [AgentAPI Documentation](https://github.com/coder/agentapi)
138141
- [Coder AI Agents Guide](https://coder.com/docs/ai-coder)

0 commit comments

Comments
 (0)