Skip to content

Commit 89e1b68

Browse files
committed
same for screen
1 parent a41954d commit 89e1b68

File tree

1 file changed

+1
-7
lines changed
  • registry/coder/modules/claude-code

1 file changed

+1
-7
lines changed

registry/coder/modules/claude-code/main.tf

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -203,15 +203,9 @@ resource "coder_script" "claude_code" {
203203
204204
screen -U -dmS claude-code bash -c '
205205
cd ${var.folder}
206-
claude --dangerously-skip-permissions | tee -a "$HOME/.claude-code.log"
206+
claude --dangerously-skip-permissions "$CODER_MCP_CLAUDE_TASK_PROMPT" | tee -a "$HOME/.claude-code.log"
207207
exec bash
208208
'
209-
# Extremely hacky way to send the prompt to the screen session
210-
# This will be fixed in the future, but `claude` was not sending MCP
211-
# tasks when an initial prompt is provided.
212-
screen -S claude-code -X stuff "$CODER_MCP_CLAUDE_TASK_PROMPT"
213-
sleep 5
214-
screen -S claude-code -X stuff "^M"
215209
else
216210
# Check if claude is installed before running
217211
if ! command_exists claude; then

0 commit comments

Comments
 (0)