Skip to content

Commit 173e6ea

Browse files
sonesukeclaude
andauthored
chore: clean up devcontainer and bump version to 0.2.2 (#77)
* chore: clean up devcontainer and update model configuration Remove unused packages (tmux, vim, yq), add chrome_args for Docker environment, and update Claude model versions. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * chore: bump version to 0.2.2 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * chore: add gh auth setup-git to devcontainer post-create Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent d02303d commit 173e6ea

3 files changed

Lines changed: 24 additions & 17 deletions

File tree

.devcontainer/Dockerfile

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@ RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
1414
pkg-config \
1515
libssl-dev \
1616
ripgrep \
17-
tmux \
18-
vim \
1917
jq \
2018
sudo \
2119
chromium \
@@ -28,14 +26,16 @@ RUN curl -fsSL https://deb.nodesource.com/setup_lts.x | bash - \
2826
&& apt-get install -y nodejs \
2927
&& apt-get clean -y && rm -rf /var/lib/apt/lists/*
3028

31-
# Install yq manually
32-
RUN curl -L https://github.com/mikefarah/yq/releases/latest/download/yq_linux_amd64 -o /usr/local/bin/yq \
33-
&& chmod +x /usr/local/bin/yq
34-
3529
# Ensure pre-installed tools are always in PATH even if CARGO_HOME is overridden at runtime
3630
ENV PATH=/usr/local/cargo/bin:$PATH
3731

3832
# Install cargo-binstall and other rust tools as root (installs to /usr/local/cargo/bin)
3933
RUN curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash \
4034
&& rustup component add rustfmt clippy llvm-tools-preview \
4135
&& cargo binstall -y cargo-audit cargo-llvm-cov
36+
37+
# Install Chromium and dependencies for browser-based MCP
38+
RUN apt-get update && apt-get install -y \
39+
chromium \
40+
chromium-common \
41+
&& apt-get clean -y && rm -rf /var/lib/apt/lists/*

.devcontainer/post-create.sh

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,6 @@ if [ -z "$CI" ] && [ -z "$GITHUB_ACTIONS" ]; then
1919
echo "[Devcontainer Setup] Claude CLI already installed: $(claude --version)"
2020
fi
2121

22-
echo "[Devcontainer Setup] Configuring tmux..."
23-
cat > $HOME/.tmux.conf << 'EOF'
24-
# Display pane number
25-
bind-key p display-panes
26-
set display-panes-time 10000
27-
EOF
28-
2922
echo "[Devcontainer Setup] Configuring claude alias..."
3023
echo 'alias claude="claude --allow-dangerously-skip-permissions"' >> $HOME/.bashrc
3124
echo 'alias claude="claude --allow-dangerously-skip-permissions"' >> $HOME/.zshrc
@@ -53,8 +46,16 @@ EOF
5346
# Note: chrome_args will be dynamically determined by the app
5447
echo "[Devcontainer Setup] Configuring google-patent-cli..."
5548
mkdir -p "$HOME/.config/google-patent-cli"
56-
cat > "$HOME/.config/google-patent-cli/config.toml" <<EOF
49+
cat > ~/.config/google-patent-cli/config.toml << 'EOF'
50+
# Chrome browser path
5751
browser_path = "/usr/bin/chromium"
52+
53+
# Chrome arguments for Docker/DevContainer environment
54+
chrome_args = [
55+
"--no-sandbox",
56+
"--disable-setuid-sandbox",
57+
"--disable-gpu"
58+
]
5859
EOF
5960

6061
# Run mise install
@@ -79,14 +80,20 @@ EOF
7980
"ANTHROPIC_BASE_URL": "https://api.z.ai/api/anthropic",
8081
"API_TIMEOUT_MS": "3000000",
8182
"CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC": "1",
82-
"ANTHROPIC_DEFAULT_OPUS_MODEL": "glm-5",
83-
"ANTHROPIC_DEFAULT_SONNET_MODEL": "glm-4.7",
83+
"ANTHROPIC_DEFAULT_OPUS_MODEL": "glm-5.1",
84+
"ANTHROPIC_DEFAULT_SONNET_MODEL": "glm-5-turbo",
8485
"ANTHROPIC_DEFAULT_HAIKU_MODEL": "glm-4.5-air"
8586
}
8687
}
8788
EOF
8889
fi
8990

91+
# Configure git to use gh for HTTPS auth
92+
if command -v gh >/dev/null 2>&1; then
93+
echo "[Devcontainer Setup] Configuring gh auth for git..."
94+
gh auth setup-git
95+
fi
96+
9097
echo "[Devcontainer Setup] Complete!"
9198
else
9299
echo "Running in CI environment, skipping development setup..."

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "google-patent-cli"
3-
version = "0.2.1"
3+
version = "0.2.2"
44
edition = "2024"
55
rust-version = "1.93"
66

0 commit comments

Comments
 (0)