g1t/apps/web/app/components/clone-box.tsx
Pick any line to see why it is the way it is: the commit, the pull request and issue it came from, and what the agent was thinking.
| Hosted agents: sandboxes on Cloudflare Containers started from an intent | 1 | import { Link } from "react-router"; |
| 2 | ||
| 3 | import { CopyLine } from "./ui"; | |
| 4 | import { Tabs, TabsContent, TabsList, TabsTrigger } from "./ui/tabs"; | |
| 5 | ||
| 6 | /** The ways to get a repository onto a machine or in front of an agent. */ | |
| 7 | export function CloneBox({ path }: { path: string }) { | |
| 8 | return ( | |
| 9 | <Tabs defaultValue="https"> | |
| 10 | <TabsList> | |
| 11 | <TabsTrigger value="https">HTTPS</TabsTrigger> | |
| 12 | <TabsTrigger value="ssh">SSH</TabsTrigger> | |
| 13 | <TabsTrigger value="agent">Agent</TabsTrigger> | |
| 14 | </TabsList> | |
| 15 | <TabsContent value="https"> | |
| 16 | <CopyLine text={`https://g1t.sh/${path}.git`} /> | |
| 17 | <p className="mt-2 text-xs text-muted"> | |
| 18 | To push, use your username and an{" "} | |
| 19 | <Link to="/settings" className="text-fg underline underline-offset-4"> | |
| 20 | access token | |
| 21 | </Link>{" "} | |
| 22 | as the password. | |
| 23 | </p> | |
| 24 | </TabsContent> | |
| 25 | <TabsContent value="ssh"> | |
| 26 | <p className="rounded-lg border border-dashed border-line p-3 text-xs text-muted"> | |
| 27 | Git over SSH is not available yet. Use HTTPS for now. | |
| 28 | </p> | |
| 29 | </TabsContent> | |
| 30 | <TabsContent value="agent"> | |
| 31 | <CopyLine | |
| 32 | prompt | |
| 33 | text='claude mcp add --transport http g1t https://mcp.g1t.sh --header "Authorization: Bearer $G1T_TOKEN"' | |
| 34 | /> | |
| 35 | <p className="mt-2 text-xs text-muted"> | |
| 36 | Connects Claude Code to g1t. Then ask it to work on an intent in{" "} | |
| 37 | <span className="font-mono text-fg">{path}</span>.{" "} | |
| 38 | <Link to="/docs/agents" className="text-fg underline underline-offset-4"> | |
| 39 | More | |
| 40 | </Link> | |
| 41 | </p> | |
| 42 | </TabsContent> | |
| 43 | </Tabs> | |
| 44 | ); | |
| 45 | } |