Skip to content

Commit b4e9545

Browse files
authored
fix(claude-code): source bashrc file only if it exists (#459)
1 parent 50ac3b3 commit b4e9545

File tree

3 files changed

+10
-6
lines changed

3 files changed

+10
-6
lines changed

registry/coder/modules/claude-code/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Run the [Claude Code](https://docs.anthropic.com/en/docs/agents-and-tools/claude
1313
```tf
1414
module "claude-code" {
1515
source = "registry.coder.com/coder/claude-code/coder"
16-
version = "3.0.1"
16+
version = "3.0.2"
1717
agent_id = coder_agent.example.id
1818
workdir = "/home/coder/project"
1919
claude_api_key = "xxxx-xxxxx-xxxx"
@@ -49,7 +49,7 @@ data "coder_parameter" "ai_prompt" {
4949
5050
module "claude-code" {
5151
source = "registry.coder.com/coder/claude-code/coder"
52-
version = "3.0.1"
52+
version = "3.0.2"
5353
agent_id = coder_agent.example.id
5454
workdir = "/home/coder/project"
5555
@@ -85,7 +85,7 @@ Run and configure Claude Code as a standalone CLI in your workspace.
8585
```tf
8686
module "claude-code" {
8787
source = "registry.coder.com/coder/claude-code/coder"
88-
version = "3.0.1"
88+
version = "3.0.2"
8989
agent_id = coder_agent.example.id
9090
workdir = "/home/coder"
9191
install_claude_code = true
@@ -108,7 +108,7 @@ variable "claude_code_oauth_token" {
108108
109109
module "claude-code" {
110110
source = "registry.coder.com/coder/claude-code/coder"
111-
version = "3.0.1"
111+
version = "3.0.2"
112112
agent_id = coder_agent.example.id
113113
workdir = "/home/coder/project"
114114
claude_code_oauth_token = var.claude_code_oauth_token

registry/coder/modules/claude-code/scripts/install.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
#!/bin/bash
22
set -euo pipefail
33

4-
source "$HOME"/.bashrc
4+
if [ -f "$HOME/.bashrc" ]; then
5+
source "$HOME"/.bashrc
6+
fi
57

68
BOLD='\033[0;1m'
79

registry/coder/modules/claude-code/scripts/start.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
#!/bin/bash
22
set -euo pipefail
33

4-
source "$HOME"/.bashrc
4+
if [ -f "$HOME/.bashrc" ]; then
5+
source "$HOME"/.bashrc
6+
fi
57
export PATH="$HOME/.local/bin:$PATH"
68

79
command_exists() {

0 commit comments

Comments
 (0)