refactor: remove bundled Claude Code binary support

- Remove all bundled/sidecar binary functionality
- Delete build scripts for fetching and building Claude executables
- Simplify binary detection to only support system installations
- Update UI to remove bundled installation options
- Update build configuration and documentation
This commit is contained in:
Vivek R
2025-07-22 21:16:20 +05:30
parent abc7323194
commit 4ddb6a1995
15 changed files with 40 additions and 1568 deletions

View File

@@ -6,7 +6,7 @@ import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/com
import { Label } from "@/components/ui/label";
import { api, type ClaudeInstallation } from "@/lib/api";
import { cn } from "@/lib/utils";
import { CheckCircle, Package, HardDrive, Settings } from "lucide-react";
import { CheckCircle, HardDrive, Settings } from "lucide-react";
interface ClaudeVersionSelectorProps {
/**
@@ -37,7 +37,7 @@ interface ClaudeVersionSelectorProps {
/**
* ClaudeVersionSelector component for selecting Claude Code installations
* Supports bundled sidecar, system installations, and user preferences
* Supports system installations and user preferences
*
* @example
* <ClaudeVersionSelector
@@ -108,8 +108,6 @@ export const ClaudeVersionSelector: React.FC<ClaudeVersionSelectorProps> = ({
const getInstallationIcon = (installation: ClaudeInstallation) => {
switch (installation.installation_type) {
case "Bundled":
return <Package className="h-4 w-4" />;
case "System":
return <HardDrive className="h-4 w-4" />;
case "Custom":
@@ -121,8 +119,6 @@ export const ClaudeVersionSelector: React.FC<ClaudeVersionSelectorProps> = ({
const getInstallationTypeColor = (installation: ClaudeInstallation) => {
switch (installation.installation_type) {
case "Bundled":
return "bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-300";
case "System":
return "bg-blue-100 text-blue-800 dark:bg-blue-900 dark:text-blue-300";
case "Custom":
@@ -165,7 +161,6 @@ export const ClaudeVersionSelector: React.FC<ClaudeVersionSelectorProps> = ({
);
}
const bundledInstallations = installations.filter(i => i.installation_type === "Bundled");
const systemInstallations = installations.filter(i => i.installation_type === "System");
const customInstallations = installations.filter(i => i.installation_type === "Custom");
@@ -177,7 +172,7 @@ export const ClaudeVersionSelector: React.FC<ClaudeVersionSelectorProps> = ({
Claude Code Installation
</CardTitle>
<CardDescription>
Choose your preferred Claude Code installation. Bundled version is recommended for best compatibility.
Choose your preferred Claude Code installation.
</CardDescription>
</CardHeader>
<CardContent className="space-y-6">
@@ -199,28 +194,6 @@ export const ClaudeVersionSelector: React.FC<ClaudeVersionSelectorProps> = ({
</SelectValue>
</SelectTrigger>
<SelectContent>
{bundledInstallations.length > 0 && (
<>
<div className="px-2 py-1.5 text-xs font-semibold text-muted-foreground">Bundled</div>
{bundledInstallations.map((installation) => (
<SelectItem key={installation.path} value={installation.path}>
<div className="flex items-center gap-2 w-full">
{getInstallationIcon(installation)}
<div className="flex-1 min-w-0">
<div className="font-medium">Claude Code (Bundled)</div>
<div className="text-xs text-muted-foreground">
{installation.version || "Version unknown"} {installation.source}
</div>
</div>
<Badge variant="secondary" className={cn("text-xs", getInstallationTypeColor(installation))}>
Recommended
</Badge>
</div>
</SelectItem>
))}
</>
)}
{systemInstallations.length > 0 && (
<>
<div className="px-2 py-1.5 text-xs font-semibold text-muted-foreground">System Installations</div>

View File

@@ -429,7 +429,7 @@ export const Settings: React.FC<SettingsProps> = ({
<div>
<Label className="text-sm font-medium mb-2 block">Claude Code Installation</Label>
<p className="text-xs text-muted-foreground mb-4">
Select which Claude Code installation to use. Bundled version is recommended for best compatibility.
Select which Claude Code installation to use.
</p>
</div>
<ClaudeVersionSelector

View File

@@ -99,14 +99,14 @@ export interface FileEntry {
* Represents a Claude installation found on the system
*/
export interface ClaudeInstallation {
/** Full path to the Claude binary (or "claude-code" for sidecar) */
/** Full path to the Claude binary */
path: string;
/** Version string if available */
version?: string;
/** Source of discovery (e.g., "nvm", "system", "homebrew", "which", "bundled") */
/** Source of discovery (e.g., "nvm", "system", "homebrew", "which") */
source: string;
/** Type of installation */
installation_type: "Bundled" | "System" | "Custom";
installation_type: "System" | "Custom";
}
// Agent API types