8000 feat: add claude_code_web in claude-code by BrunoQuaresma · Pull Request #135 · coder/registry · GitHub
[go: up one dir, main page]

Skip to content

feat: add claude_code_web in claude-code #135

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 15 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
comment out the claude-code app temporarily
  • Loading branch information
hugodutka committed Jun 5, 2025
commit 1551c17413f997fc62fe50fa6855de805642361d
88 changes: 44 additions & 44 deletions registry/coder/modules/claude-code/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -252,47 +252,47 @@ resource "coder_app" "claude_code_web" {
}
}

resource "coder_app" "claude_code" {
slug = "claude-code"
display_name = "Claude Code"
agent_id = var.agent_id
command = <<-EOT
#!/bin/bash
set -e

export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-8

if [ "${var.experiment_use_tmux}" = "true" ]; then

if ! tmux has-session -t claude-code-agentapi 2>/dev/null; then
echo "Starting a new Claude Code agentapi tmux session." | tee -a "$HOME/.claude-code.log"
# use low width to fit in the tasks UI sidebar. height is adjusted to ~match the default 80k (80x1000) characters
# visible in the terminal screen.
tmux new-session -d -s claude-code-agentapi -c ${var.folder} 'agentapi server --term-width 67 --term-height 1190 -- bash -c "claude --dangerously-skip-permissions"; exec bash'
fi

if tmux has-session -t claude-code 2>/dev/null; then
echo "Attaching to existing Claude Code tmux session." | tee -a "$HOME/.claude-code.log"
tmux attach-session -t claude-code
else
echo "Starting a new Claude Code tmux session." | tee -a "$HOME/.claude-code.log"
tmux new-session -s claude-code -c ${var.folder} "agentapi attach; exec bash"
fi
elif [ "${var.experiment_use_screen}" = "true" ]; then
if screen -list | grep -q "claude-code"; then
echo "Attaching to existing Claude Code screen session." | tee -a "$HOME/.claude-code.log"
screen -xRR claude-code
else
echo "Starting a new Claude Code screen session." | tee -a "$HOME/.claude-code.log"
screen -S claude-code bash -c 'agentapi attach; exec bash'
fi
else
cd ${var.folder}
claude
fi
EOT
icon = var.icon
order = var.order
group = var.group
}
# resource "coder_app" "claude_code" {
# slug = "claude-code"
# display_name = "Claude Code"
# agent_id = var.agent_id
# command = <<-EOT
# #!/bin/bash
# set -e

# export LANG=en_US.UTF-8
# export LC_ALL=en_US.UTF-8

# if [ "${var.experiment_use_tmux}" = "true" ]; then

# if ! tmux has-session -t claude-code-agentapi 2>/dev/null; then
# echo "Starting a new Claude Code agentapi tmux session." | tee -a "$HOME/.claude-code.log"
# # use low width to fit in the tasks UI sidebar. height is adjusted to ~match the default 80k (80x1000) characters
# # visible in the terminal screen.
# tmux new-session -d -s claude-code-agentapi -c ${var.folder} 'agentapi server --term-width 67 --term-height 1190 -- bash -c "claude --dangerously-skip-permissions"; exec bash'
# fi

# if tmux has-session -t claude-code 2>/dev/null; then
# echo "Attaching to existing Claude Code tmux session." | tee -a "$HOME/.claude-code.log"
# tmux attach-session -t claude-code
# else
# echo "Starting a new Claude Code tmux session." | tee -a "$HOME/.claude-code.log"
# tmux new-session -s claude-code -c ${var.folder} "agentapi attach; exec bash"
# fi
# elif [ "${var.experiment_use_screen}" = "true" ]; then
# if screen -list | grep -q "claude-code"; then
# echo "Attaching to existing Claude Code screen session." | tee -a "$HOME/.claude-code.log"
# screen -xRR claude-code
# else
# echo "Starting a new Claude Code screen session." | tee -a "$HOME/.claude-code.log"
# screen -S claude-code bash -c 'agentapi attach; exec bash'
# fi
# else
# cd ${var.folder}
# claude
# fi
# EOT
# icon = var.icon
# order = var.order
# group = var.group
# }
Loading
0