[{"data":1,"prerenderedAt":2365},["ShallowReactive",2],{"navigation":3,"/node-tools/opencode-cli":458,"/node-tools/opencode-cli-surround":2362},[4,58,91,178,194,201,249,295,315,371,435,449],{"title":5,"path":6,"stem":7,"children":8,"icon":57},"MacOS","/macos","01.macos/01.index",[9,12,17,22,27,32,37,42,47,52],{"title":10,"path":6,"stem":7,"icon":11},"Introduction","i-lucide-house",{"title":13,"path":14,"stem":15,"icon":16},"Recommended Software","/macos/recommended-software","01.macos/02.recommended-software","i-lucide-laptop",{"title":18,"path":19,"stem":20,"icon":21},"Development Applications and Tools","/macos/development-tools","01.macos/03.development-tools","i-lucide-folder-code",{"title":23,"path":24,"stem":25,"icon":26},"Command Line Interface","/macos/cli-tools","01.macos/04.cli-tools","i-lucide-terminal",{"title":28,"path":29,"stem":30,"icon":31},"ZSH Configuration","/macos/zshrc","01.macos/05.zshrc","i-simple-icons-zsh",{"title":33,"path":34,"stem":35,"icon":36},"Uninstall Python","/macos/uninstall-python","01.macos/06.uninstall-python","i-simple-icons-python",{"title":38,"path":39,"stem":40,"icon":41},"Mac Mini Server Setup","/macos/mac-mini-server","01.macos/07.mac-mini-server","i-lucide-server",{"title":43,"path":44,"stem":45,"icon":46},"Image to 3D Model","/macos/image-to-3d","01.macos/08.image-to-3d","i-lucide-rotate-3d",{"title":48,"path":49,"stem":50,"icon":51},"NSVisualEffectView","/macos/material-view","01.macos/09.material-view","i-lucide-layers",{"title":53,"path":54,"stem":55,"icon":56},"SSH","/macos/ssh","01.macos/10.ssh","i-lucide-key-round","i-simple-icons-macos",{"title":59,"path":60,"stem":61,"children":62,"icon":90},"Windows","/windows","02.windows/01.index",[63,64,67,70,75,80,85],{"title":10,"path":60,"stem":61,"icon":11},{"title":13,"path":65,"stem":66,"icon":21},"/windows/recommended-software","02.windows/02.recommended-software",{"title":23,"path":68,"stem":69,"icon":26},"/windows/cli-tools","02.windows/03.cli-tools",{"title":71,"path":72,"stem":73,"icon":74},"Miscellaneous Tips","/windows/miscellaneous-tips","02.windows/04.miscellaneous-tips","i-lucide-lightbulb",{"title":76,"path":77,"stem":78,"icon":79},"Keyboard Shortcuts","/windows/keyboard-shortcuts","02.windows/05.keyboard-shortcuts","i-lucide-keyboard",{"title":81,"path":82,"stem":83,"icon":84},"WSL - Arch Linux","/windows/wsl-arch-linux","02.windows/06.wsl-arch-linux","i-simple-icons-archlinux",{"title":86,"path":87,"stem":88,"icon":89},"VirtualBox on Windows","/windows/virtualbox","02.windows/07.virtualbox","i-simple-icons-virtualbox","i-simple-icons-windows",{"title":92,"path":93,"stem":94,"children":95,"icon":177},"Rust","/rust","03.rust/01.index",[96,98,103,108,113,118,123,128,132,136,140,144,148,152,156,161,165,169,173],{"title":97,"path":93,"stem":94,"icon":26},"Installation",{"title":99,"path":100,"stem":101,"icon":102},"Continuous Integration","/rust/ci","03.rust/02.ci","i-lucide-workflow",{"title":104,"path":105,"stem":106,"icon":107},"Benchmarking with Criterion","/rust/benchmarking","03.rust/03.benchmarking","i-lucide-timer",{"title":109,"path":110,"stem":111,"icon":112},"Publishing Crates","/rust/publishing-crates","03.rust/04.publishing-crates","i-lucide-package",{"title":114,"path":115,"stem":116,"icon":117},"Multi-Crate Dependency Management","/rust/multi-crate-dependencies","03.rust/05.multi-crate-dependencies","i-lucide-git-branch",{"title":119,"path":120,"stem":121,"icon":122},"Just Task Runner","/rust/just-task-runner","03.rust/06.just-task-runner","i-lucide-play",{"title":124,"path":125,"stem":126,"icon":127},"Error Handling Patterns","/rust/error-handling","03.rust/07.error-handling","i-lucide-alert-triangle",{"title":129,"path":130,"stem":131},"Mutation Testing","/rust/mutation-testing","03.rust/08.mutation-testing",{"title":133,"path":134,"stem":135},"Semver Compliance with cargo-semver-checks","/rust/semver-checks","03.rust/09.semver-checks",{"title":137,"path":138,"stem":139},"Property-Based Testing","/rust/property-testing","03.rust/10.property-testing",{"title":141,"path":142,"stem":143},"Workspace Automation","/rust/workspace-automation","03.rust/11.workspace-automation",{"title":145,"path":146,"stem":147},"Type-Safe Units","/rust/type-safe-units","03.rust/12.type-safe-units",{"title":149,"path":150,"stem":151},"Faster Testing with nextest","/rust/nextest","03.rust/13.nextest",{"title":153,"path":154,"stem":155},"Cross-Crate Validation Testing","/rust/cross-crate-validation","03.rust/14.cross-crate-validation",{"title":157,"path":158,"stem":159,"icon":160},"Defensive API Design","/rust/defensive-api-design","03.rust/15.defensive-api-design","i-lucide-shield",{"title":162,"path":163,"stem":164},"Structured Logging with tracing","/rust/tracing","03.rust/16.tracing",{"title":166,"path":167,"stem":168},"Feature Flags & Conditional Compilation","/rust/feature-flags","03.rust/17.feature-flags",{"title":170,"path":171,"stem":172},"Debugging Rust","/rust/debugging","03.rust/18.debugging",{"title":174,"path":175,"stem":176},"Production-Ready Rust CLI Workflow","/rust/production-cli-workflow","03.rust/18.production-cli-workflow","i-simple-icons-rust",{"title":179,"path":180,"stem":181,"children":182,"icon":36},"Python","/python","04.python/01.index",[183,184,189],{"title":97,"path":180,"stem":181,"icon":26},{"title":185,"path":186,"stem":187,"icon":188},"Optionally Callable Decorators","/python/decorators","04.python/02.decorators","i-lucide-at-sign",{"title":190,"path":191,"stem":192,"icon":193},"Pre-commit, with uv","/python/pre-commit","04.python/03.pre-commit","i-simple-icons-precommit",{"title":195,"path":196,"stem":197,"children":198,"icon":200},"Go","/go","05.go/01.index",[199],{"title":97,"path":196,"stem":197,"icon":26},"i-simple-icons-go",{"title":202,"path":203,"stem":204,"children":205,"icon":248},"Web Design","/webdesign","06.webdesign/01.index",[206,209,214,219,224,229,234,239,244],{"title":207,"path":203,"stem":204,"icon":208},"Icons","i-simple-icons-lucide",{"title":210,"path":211,"stem":212,"icon":213},"CSS","/webdesign/css","06.webdesign/02.css","i-simple-icons-css",{"title":215,"path":216,"stem":217,"icon":218},"Captive Portals","/webdesign/captive-portals","06.webdesign/03.captive-portals","i-lucide-wifi",{"title":220,"path":221,"stem":222,"icon":223},"URL Pattern API","/webdesign/url-pattern","06.webdesign/04.url-pattern","i-lucide-link",{"title":225,"path":226,"stem":227,"icon":228},"Hidden Until Found","/webdesign/hidden-until-found","06.webdesign/05.hidden-until-found","i-lucide-search",{"title":230,"path":231,"stem":232,"icon":233},"Login Patterns","/webdesign/login-patterns","06.webdesign/06.login-patterns","i-lucide-log-in",{"title":235,"path":236,"stem":237,"icon":238},"Typography","/webdesign/typography","06.webdesign/07.typography","i-lucide-type",{"title":240,"path":241,"stem":242,"icon":243},"UI Details","/webdesign/ui-details","06.webdesign/08.ui-details","i-lucide-sparkles",{"title":245,"path":246,"stem":247},"Draftboard","/webdesign/draftboard","06.webdesign/09.draftboard","i-lucide-arrow-down-up",{"title":250,"icon":251,"path":252,"stem":253,"children":254,"page":294},"Health","i-lucide-heart-pulse","/health","07.health",[255,260,265,270,275,280,285,290],{"title":256,"path":257,"stem":258,"icon":259},"ADHD and Sleep Cycles","/health/adhd-sleep","07.health/02.adhd-sleep","i-lucide-moon",{"title":261,"path":262,"stem":263,"icon":264},"Daily Health Habits","/health/daily-health-habits","07.health/03.daily-health-habits","i-lucide-list-checks",{"title":266,"path":267,"stem":268,"icon":269},"Calm Down Posture","/health/calm-down-posture","07.health/04.calm-down-posture","i-lucide-bed",{"title":271,"path":272,"stem":273,"icon":274},"Mood Switch on Your Face","/health/mood-face","07.health/05.mood-face","i-lucide-smile",{"title":276,"path":277,"stem":278,"icon":279},"Baby Gas Relief","/health/baby-gas-relief","07.health/06.baby-gas-relief","i-lucide-baby",{"title":281,"path":282,"stem":283,"icon":284},"Fast Acting Wound Sealer","/health/wound-sealer","07.health/07.wound-sealer","i-lucide-bandage",{"title":286,"path":287,"stem":288,"icon":289},"Water Flosser","/health/waterpick","07.health/08.waterpick","i-lucide-droplets",{"title":291,"path":292,"stem":293},"Meal Timing & Sleep","/health/meal-timing","07.health/09.meal-timing",false,{"title":296,"icon":297,"path":298,"stem":299,"children":300,"page":294},"Strategy","i-lucide-target","/strategy","08.strategy",[301,305,310],{"title":302,"path":303,"stem":304,"icon":297},"Jobs to Be Done","/strategy/jobs-to-be-done","08.strategy/02.jobs-to-be-done",{"title":306,"path":307,"stem":308,"icon":309},"Pillars of Money","/strategy/pillars-of-money","08.strategy/03.pillars-of-money","i-lucide-landmark",{"title":311,"path":312,"stem":313,"icon":314},"Marketing","/strategy/marketing","08.strategy/04.marketing","i-lucide-megaphone",{"title":316,"icon":317,"path":318,"stem":319,"children":320,"page":294},"Artificial Intelligence","i-lucide-brain","/ai","09.ai",[321,325,330,334,338,342,347,352,357,362,366],{"title":322,"path":323,"stem":324},"Linear + Cursor + Codex Workflow Integration","/ai/workflow-integration","09.ai/01.workflow-integration",{"title":326,"path":327,"stem":328,"icon":329},"Fabric","/ai/fabric","09.ai/02.fabric","i-lucide-cpu",{"title":331,"path":332,"stem":333},"OpenCode: Open Source AI Coding Agent","/ai/opencode-agent","09.ai/02.opencode-agent",{"title":335,"path":336,"stem":337},"Kimi K2.5 + Fireworks AI + OpenCode: Cost-Effective Daily Driver","/ai/kimi-k25-fireworks-opencode","09.ai/03.kimi-k25-fireworks-opencode",{"title":339,"path":340,"stem":341,"icon":259},"Looping Agents at Night","/ai/looping-agents","09.ai/03.looping-agents",{"title":343,"path":344,"stem":345,"icon":346},"Real ML Systems","/ai/real-ml-systems","09.ai/04.real-ml-systems","i-lucide-factory",{"title":348,"path":349,"stem":350,"icon":351},"AI Ralph","/ai/ai-ralph","09.ai/05.ai-ralph","i-lucide-bot",{"title":353,"path":354,"stem":355,"icon":356},"ChatGPT Prompt Techniques","/ai/chatgpt-prompts","09.ai/06.chatgpt-prompts","i-lucide-message-square-text",{"title":358,"path":359,"stem":360,"icon":361},"AI Courses","/ai/ai-courses","09.ai/07.ai-courses","i-lucide-graduation-cap",{"title":363,"path":364,"stem":365,"icon":208},"Claude & Codex Skills","/ai/claude-codex-skills","09.ai/08.claude-codex-skills",{"title":367,"path":368,"stem":369,"icon":370},"OpenDataLoader PDF","/ai/opendataloader-pdf","09.ai/09.opendataloader-pdf","i-lucide-file-text",{"title":372,"icon":329,"path":373,"stem":374,"children":375,"page":294},"Engineering","/engineering","10.engineering",[376,381,386,391,396,401,406,411,416,421,426,431],{"title":377,"path":378,"stem":379,"icon":380},"Aircraft Wing Design","/engineering/aircraft-wing-design","10.engineering/02.aircraft-wing-design","i-lucide-plane",{"title":382,"path":383,"stem":384,"icon":385},"Machinery's Handbook","/engineering/machinery-handbook","10.engineering/03.machinery-handbook","i-lucide-wrench",{"title":387,"path":388,"stem":389,"icon":390},"KiCAD Circuit Snips","/engineering/kicad-circuit-snips","10.engineering/04.kicad-circuit-snips","i-lucide-copy",{"title":392,"path":393,"stem":394,"icon":395},"Enamel Wire for Rework","/engineering/enamel-wire-rework","10.engineering/05.enamel-wire-rework","i-lucide-cable",{"title":397,"path":398,"stem":399,"icon":400},"Treating Steel","/engineering/treating-steel","10.engineering/06.treating-steel","i-lucide-flame",{"title":402,"path":403,"stem":404,"icon":405},"Knipex vs Lindstrom","/engineering/knipex-vs-lindstrom","10.engineering/07.knipex-vs-lindstrom","i-lucide-scissors",{"title":407,"path":408,"stem":409,"icon":410},"Gel-Pak Tack Levels","/engineering/gel-pack-tack","10.engineering/08.gel-pack-tack","i-lucide-grip",{"title":412,"path":413,"stem":414,"icon":415},"Antenna Radiation Patterns","/engineering/antenna-patterns","10.engineering/09.antenna-patterns","i-lucide-radio",{"title":417,"path":418,"stem":419,"icon":420},"Codesign Hardware and Software","/engineering/codesign-hw-sw","10.engineering/10.codesign-hw-sw","i-lucide-circuit-board",{"title":422,"path":423,"stem":424,"icon":425},"Plasticity CAD","/engineering/plasticity-cad","10.engineering/11.plasticity-cad","i-lucide-box",{"title":427,"path":428,"stem":429,"icon":430},"Mission Assurance","/engineering/mission-assurance","10.engineering/12.mission-assurance","i-lucide-shield-check",{"title":432,"path":433,"stem":434},"Google Search Operators","/engineering/google-search-operators","10.engineering/13.google-search-operators",{"title":436,"icon":437,"path":438,"stem":439,"children":440,"page":294},"Learning","i-lucide-book-open","/learning","11.learning",[441,445],{"title":442,"path":443,"stem":444,"icon":74},"Art of Problem Solving","/learning/art-of-problem-solving","11.learning/02.art-of-problem-solving",{"title":446,"path":447,"stem":448,"icon":400},"Do the Work","/learning/do-the-work","11.learning/03.do-the-work",{"title":450,"icon":26,"path":451,"stem":452,"children":453,"page":294},"Node Tools & CLI","/node-tools","12.node-tools",[454],{"title":455,"path":456,"stem":457},"OpenCode: AI Coding Agent for Terminal & CLI","/node-tools/opencode-cli","12.node-tools/01.opencode-cli",{"id":459,"title":455,"body":460,"description":2356,"extension":2357,"links":2358,"meta":2359,"navigation":528,"path":456,"seo":2360,"stem":457,"__hash__":2361},"docs/12.node-tools/01.opencode-cli.md",{"type":461,"value":462,"toc":2291},"minimark",[463,467,475,478,483,573,575,579,584,590,626,630,645,649,654,696,700,737,740,745,759,764,778,782,796,801,823,827,878,880,884,888,891,901,906,941,945,948,988,990,994,998,1007,1010,1014,1017,1025,1028,1059,1063,1066,1082,1085,1091,1098,1102,1105,1111,1113,1117,1121,1161,1165,1207,1211,1253,1257,1289,1291,1295,1299,1306,1309,1320,1325,1331,1334,1340,1344,1347,1352,1358,1361,1367,1369,1373,1377,1383,1386,1400,1404,1410,1413,1419,1422,1428,1431,1437,1441,1447,1450,1464,1468,1474,1477,1481,1487,1493,1496,1510,1512,1516,1520,1529,1597,1600,1606,1609,1613,1620,1721,1723,1727,1731,1734,1840,1842,1846,1850,1853,1856,1862,1865,1871,1875,1878,1884,1888,1895,1901,1905,1908,1914,1917,1921,1924,1930,1933,1939,1941,1945,1949,1952,1963,1967,1972,1975,1986,1990,1995,1998,2002,2012,2014,2018,2022,2025,2045,2048,2073,2077,2092,2096,2119,2121,2125,2143,2146,2148,2152,2169,2171,2175,2222,2224,2228,2279,2281,2287],[464,465,455],"h1",{"id":466},"opencode-ai-coding-agent-for-terminal-cli",[468,469,470,474],"p",{},[471,472,473],"strong",{},"OpenCode"," is a full-featured AI coding agent available as a command-line tool, with optional IDE and desktop integrations. It's built on Node.js and works on macOS, Linux, and Windows.",[476,477],"hr",{},[479,480,482],"h2",{"id":481},"quick-install","Quick Install",[484,485,490],"pre",{"className":486,"code":487,"language":488,"meta":489,"style":489},"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","# Recommended: Install script\ncurl -fsSL https://opencode.ai/install | bash\n\n# Or via npm\nnpm install -g opencode-ai\n\n# Or via Homebrew (macOS)\nbrew install anomalyco/tap/opencode\n","bash","",[491,492,493,502,523,530,536,551,556,562],"code",{"__ignoreMap":489},[494,495,498],"span",{"class":496,"line":497},"line",1,[494,499,501],{"class":500},"sHwdD","# Recommended: Install script\n",[494,503,505,509,513,516,520],{"class":496,"line":504},2,[494,506,508],{"class":507},"sBMFI","curl",[494,510,512],{"class":511},"sfazB"," -fsSL",[494,514,515],{"class":511}," https://opencode.ai/install",[494,517,519],{"class":518},"sMK4o"," |",[494,521,522],{"class":507}," bash\n",[494,524,526],{"class":496,"line":525},3,[494,527,529],{"emptyLinePlaceholder":528},true,"\n",[494,531,533],{"class":496,"line":532},4,[494,534,535],{"class":500},"# Or via npm\n",[494,537,539,542,545,548],{"class":496,"line":538},5,[494,540,541],{"class":507},"npm",[494,543,544],{"class":511}," install",[494,546,547],{"class":511}," -g",[494,549,550],{"class":511}," opencode-ai\n",[494,552,554],{"class":496,"line":553},6,[494,555,529],{"emptyLinePlaceholder":528},[494,557,559],{"class":496,"line":558},7,[494,560,561],{"class":500},"# Or via Homebrew (macOS)\n",[494,563,565,568,570],{"class":496,"line":564},8,[494,566,567],{"class":507},"brew",[494,569,544],{"class":511},[494,571,572],{"class":511}," anomalyco/tap/opencode\n",[476,574],{},[479,576,578],{"id":577},"installation-options","Installation Options",[580,581,583],"h3",{"id":582},"macos","macOS",[468,585,586,589],{},[471,587,588],{},"Homebrew (Recommended)",":",[484,591,593],{"className":486,"code":592,"language":488,"meta":489,"style":489},"# Add the anomalyco tap for latest releases\nbrew install anomalyco/tap/opencode\n\n# Alternative: Official Homebrew formula (updated less frequently)\nbrew install opencode\n",[491,594,595,600,608,612,617],{"__ignoreMap":489},[494,596,597],{"class":496,"line":497},[494,598,599],{"class":500},"# Add the anomalyco tap for latest releases\n",[494,601,602,604,606],{"class":496,"line":504},[494,603,567],{"class":507},[494,605,544],{"class":511},[494,607,572],{"class":511},[494,609,610],{"class":496,"line":525},[494,611,529],{"emptyLinePlaceholder":528},[494,613,614],{"class":496,"line":532},[494,615,616],{"class":500},"# Alternative: Official Homebrew formula (updated less frequently)\n",[494,618,619,621,623],{"class":496,"line":538},[494,620,567],{"class":507},[494,622,544],{"class":511},[494,624,625],{"class":511}," opencode\n",[468,627,628,589],{},[471,629,541],{},[484,631,633],{"className":486,"code":632,"language":488,"meta":489,"style":489},"npm install -g opencode-ai\n",[491,634,635],{"__ignoreMap":489},[494,636,637,639,641,643],{"class":496,"line":497},[494,638,541],{"class":507},[494,640,544],{"class":511},[494,642,547],{"class":511},[494,644,550],{"class":511},[580,646,648],{"id":647},"linux","Linux",[468,650,651,589],{},[471,652,653],{},"Arch Linux",[484,655,657],{"className":486,"code":656,"language":488,"meta":489,"style":489},"# Stable release\nsudo pacman -S opencode\n\n# Latest from AUR\nparu -S opencode-bin\n",[491,658,659,664,677,681,686],{"__ignoreMap":489},[494,660,661],{"class":496,"line":497},[494,662,663],{"class":500},"# Stable release\n",[494,665,666,669,672,675],{"class":496,"line":504},[494,667,668],{"class":507},"sudo",[494,670,671],{"class":511}," pacman",[494,673,674],{"class":511}," -S",[494,676,625],{"class":511},[494,678,679],{"class":496,"line":525},[494,680,529],{"emptyLinePlaceholder":528},[494,682,683],{"class":496,"line":532},[494,684,685],{"class":500},"# Latest from AUR\n",[494,687,688,691,693],{"class":496,"line":538},[494,689,690],{"class":507},"paru",[494,692,674],{"class":511},[494,694,695],{"class":511}," opencode-bin\n",[468,697,698,589],{},[471,699,541],{},[484,701,703],{"className":486,"code":702,"language":488,"meta":489,"style":489},"npm install -g opencode-ai\n\n# Using Mise (Node version manager)\nmise use -g github:anomalyco/opencode\n",[491,704,705,715,719,724],{"__ignoreMap":489},[494,706,707,709,711,713],{"class":496,"line":497},[494,708,541],{"class":507},[494,710,544],{"class":511},[494,712,547],{"class":511},[494,714,550],{"class":511},[494,716,717],{"class":496,"line":504},[494,718,529],{"emptyLinePlaceholder":528},[494,720,721],{"class":496,"line":525},[494,722,723],{"class":500},"# Using Mise (Node version manager)\n",[494,725,726,729,732,734],{"class":496,"line":532},[494,727,728],{"class":507},"mise",[494,730,731],{"class":511}," use",[494,733,547],{"class":511},[494,735,736],{"class":511}," github:anomalyco/opencode\n",[580,738,59],{"id":739},"windows",[468,741,742,589],{},[471,743,744],{},"Chocolatey",[484,746,748],{"className":486,"code":747,"language":488,"meta":489,"style":489},"choco install opencode\n",[491,749,750],{"__ignoreMap":489},[494,751,752,755,757],{"class":496,"line":497},[494,753,754],{"class":507},"choco",[494,756,544],{"class":511},[494,758,625],{"class":511},[468,760,761,589],{},[471,762,763],{},"Scoop",[484,765,767],{"className":486,"code":766,"language":488,"meta":489,"style":489},"scoop install opencode\n",[491,768,769],{"__ignoreMap":489},[494,770,771,774,776],{"class":496,"line":497},[494,772,773],{"class":507},"scoop",[494,775,544],{"class":511},[494,777,625],{"class":511},[468,779,780,589],{},[471,781,541],{},[484,783,784],{"className":486,"code":632,"language":488,"meta":489,"style":489},[491,785,786],{"__ignoreMap":489},[494,787,788,790,792,794],{"class":496,"line":497},[494,789,541],{"class":507},[494,791,544],{"class":511},[494,793,547],{"class":511},[494,795,550],{"class":511},[468,797,798,589],{},[471,799,800],{},"Docker",[484,802,804],{"className":486,"code":803,"language":488,"meta":489,"style":489},"docker run -it --rm ghcr.io/anomalyco/opencode\n",[491,805,806],{"__ignoreMap":489},[494,807,808,811,814,817,820],{"class":496,"line":497},[494,809,810],{"class":507},"docker",[494,812,813],{"class":511}," run",[494,815,816],{"class":511}," -it",[494,818,819],{"class":511}," --rm",[494,821,822],{"class":511}," ghcr.io/anomalyco/opencode\n",[580,824,826],{"id":825},"from-source","From Source",[484,828,830],{"className":486,"code":829,"language":488,"meta":489,"style":489},"git clone https://github.com/anomalyco/opencode.git\ncd opencode\nnpm install\nnpm run build\nnpm install -g .\n",[491,831,832,843,851,858,867],{"__ignoreMap":489},[494,833,834,837,840],{"class":496,"line":497},[494,835,836],{"class":507},"git",[494,838,839],{"class":511}," clone",[494,841,842],{"class":511}," https://github.com/anomalyco/opencode.git\n",[494,844,845,849],{"class":496,"line":504},[494,846,848],{"class":847},"s2Zo4","cd",[494,850,625],{"class":511},[494,852,853,855],{"class":496,"line":525},[494,854,541],{"class":507},[494,856,857],{"class":511}," install\n",[494,859,860,862,864],{"class":496,"line":532},[494,861,541],{"class":507},[494,863,813],{"class":511},[494,865,866],{"class":511}," build\n",[494,868,869,871,873,875],{"class":496,"line":538},[494,870,541],{"class":507},[494,872,544],{"class":511},[494,874,547],{"class":511},[494,876,877],{"class":511}," .\n",[476,879],{},[479,881,883],{"id":882},"prerequisites","Prerequisites",[580,885,887],{"id":886},"terminal-emulator","Terminal Emulator",[468,889,890],{},"You'll need a modern terminal that supports:",[892,893,894,898],"ul",{},[895,896,897],"li",{},"Kitty graphics protocol (for image display in terminal)",[895,899,900],{},"Unicode and ANSI color codes",[468,902,903,589],{},[471,904,905],{},"Recommended",[892,907,908,918,925,933],{},[895,909,910,917],{},[911,912,916],"a",{"href":913,"rel":914},"https://wezterm.org",[915],"nofollow","WezTerm"," (cross-platform)",[895,919,920,917],{},[911,921,924],{"href":922,"rel":923},"https://alacritty.org",[915],"Alacritty",[895,926,927,932],{},[911,928,931],{"href":929,"rel":930},"https://ghostty.org",[915],"Ghostty"," (macOS/Linux)",[895,934,935,940],{},[911,936,939],{"href":937,"rel":938},"https://sw.kovidgoyal.net/kitty/",[915],"Kitty"," (Linux/macOS)",[580,942,944],{"id":943},"api-keys","API Keys",[468,946,947],{},"You'll need credentials for at least one LLM provider:",[892,949,950,961,971,977],{},[895,951,952,955,956],{},[471,953,954],{},"OpenAI",": API key from ",[911,957,960],{"href":958,"rel":959},"https://platform.openai.com",[915],"platform.openai.com",[895,962,963,955,966],{},[471,964,965],{},"Anthropic",[911,967,970],{"href":968,"rel":969},"https://console.anthropic.com",[915],"console.anthropic.com",[895,972,973,976],{},[471,974,975],{},"GitHub Copilot",": GitHub account with Copilot enabled",[895,978,979,982,983],{},[471,980,981],{},"Any provider",": 75+ options via ",[911,984,987],{"href":985,"rel":986},"https://models.dev",[915],"models.dev",[476,989],{},[479,991,993],{"id":992},"getting-started","Getting Started",[580,995,997],{"id":996},"_1-launch-opencode","1. Launch OpenCode",[484,999,1001],{"className":486,"code":1000,"language":488,"meta":489,"style":489},"opencode\n",[491,1002,1003],{"__ignoreMap":489},[494,1004,1005],{"class":496,"line":497},[494,1006,1000],{"class":507},[468,1008,1009],{},"This opens the TUI (text user interface) with an interactive prompt.",[580,1011,1013],{"id":1012},"_2-configure-llm-provider","2. Configure LLM Provider",[468,1015,1016],{},"In the TUI, run:",[484,1018,1023],{"className":1019,"code":1021,"language":1022},[1020],"language-text","/connect\n","text",[491,1024,1021],{"__ignoreMap":489},[468,1026,1027],{},"Options:",[892,1029,1030,1036,1042,1048,1053],{},[895,1031,1032,1035],{},[471,1033,1034],{},"OpenCode Zen"," (recommended): Pre-tested models with good defaults",[895,1037,1038,1041],{},[471,1039,1040],{},"Claude"," (API key required)",[895,1043,1044,1047],{},[471,1045,1046],{},"GPT-4"," (API key or ChatGPT Plus account)",[895,1049,1050,1052],{},[471,1051,975],{}," (GitHub sign-in)",[895,1054,1055,1058],{},[471,1056,1057],{},"Custom provider"," (75+ available)",[580,1060,1062],{"id":1061},"_3-initialize-project-optional-but-recommended","3. Initialize Project (Optional but Recommended)",[468,1064,1065],{},"Navigate to your project:",[484,1067,1069],{"className":486,"code":1068,"language":488,"meta":489,"style":489},"cd ~/Projects/my-app\nopencode\n",[491,1070,1071,1078],{"__ignoreMap":489},[494,1072,1073,1075],{"class":496,"line":497},[494,1074,848],{"class":847},[494,1076,1077],{"class":511}," ~/Projects/my-app\n",[494,1079,1080],{"class":496,"line":504},[494,1081,1000],{"class":507},[468,1083,1084],{},"Then run:",[484,1086,1089],{"className":1087,"code":1088,"language":1022},[1020],"/init\n",[491,1090,1088],{"__ignoreMap":489},[468,1092,1093,1094,1097],{},"This creates an ",[491,1095,1096],{},"AGENTS.md"," file that documents your project structure, coding standards, and build/test commands. OpenCode reads this in every conversation.",[580,1099,1101],{"id":1100},"_4-start-coding","4. Start Coding",[468,1103,1104],{},"Ask OpenCode to help:",[484,1106,1109],{"className":1107,"code":1108,"language":1022},[1020],"Add authentication to the /settings route. \nLook at how it's done in /notes and use the same pattern.\n",[491,1110,1108],{"__ignoreMap":489},[476,1112],{},[479,1114,1116],{"id":1115},"key-commands","Key Commands",[580,1118,1120],{"id":1119},"navigation-mode","Navigation & Mode",[1122,1123,1124,1137],"table",{},[1125,1126,1127],"thead",{},[1128,1129,1130,1134],"tr",{},[1131,1132,1133],"th",{},"Command",[1131,1135,1136],{},"Purpose",[1138,1139,1140,1151],"tbody",{},[1128,1141,1142,1148],{},[1143,1144,1145],"td",{},[491,1146,1147],{},"Tab",[1143,1149,1150],{},"Toggle between Plan Mode and Build Mode",[1128,1152,1153,1158],{},[1143,1154,1155],{},[491,1156,1157],{},"Ctrl+C",[1143,1159,1160],{},"Exit OpenCode",[580,1162,1164],{"id":1163},"project-management","Project Management",[1122,1166,1167,1175],{},[1125,1168,1169],{},[1128,1170,1171,1173],{},[1131,1172,1133],{},[1131,1174,1136],{},[1138,1176,1177,1187,1197],{},[1128,1178,1179,1184],{},[1143,1180,1181],{},[491,1182,1183],{},"/init",[1143,1185,1186],{},"Initialize project (create AGENTS.md)",[1128,1188,1189,1194],{},[1143,1190,1191],{},[491,1192,1193],{},"/connect",[1143,1195,1196],{},"Set up or switch LLM provider",[1128,1198,1199,1204],{},[1143,1200,1201],{},[491,1202,1203],{},"/theme",[1143,1205,1206],{},"Change terminal theme",[580,1208,1210],{"id":1209},"conversation-control","Conversation Control",[1122,1212,1213,1221],{},[1125,1214,1215],{},[1128,1216,1217,1219],{},[1131,1218,1133],{},[1131,1220,1136],{},[1138,1222,1223,1233,1243],{},[1128,1224,1225,1230],{},[1143,1226,1227],{},[491,1228,1229],{},"/undo",[1143,1231,1232],{},"Revert last set of changes",[1128,1234,1235,1240],{},[1143,1236,1237],{},[491,1238,1239],{},"/redo",[1143,1241,1242],{},"Restore undone changes",[1128,1244,1245,1250],{},[1143,1246,1247],{},[491,1248,1249],{},"/share",[1143,1251,1252],{},"Generate shareable link to conversation",[580,1254,1256],{"id":1255},"model-selection","Model Selection",[1122,1258,1259,1267],{},[1125,1260,1261],{},[1128,1262,1263,1265],{},[1131,1264,1133],{},[1131,1266,1136],{},[1138,1268,1269,1279],{},[1128,1270,1271,1276],{},[1143,1272,1273],{},[491,1274,1275],{},"/model",[1143,1277,1278],{},"Switch LLM model mid-conversation",[1128,1280,1281,1286],{},[1143,1282,1283],{},[491,1284,1285],{},"/providers",[1143,1287,1288],{},"List available providers",[476,1290],{},[479,1292,1294],{"id":1293},"workflow-plan-build-verify","Workflow: Plan → Build → Verify",[580,1296,1298],{"id":1297},"mode-1-plan-mode-tab-key","Mode 1: Plan Mode (Tab key)",[468,1300,1301,1302,1305],{},"In Plan Mode, OpenCode analyzes your request and ",[471,1303,1304],{},"suggests"," an approach without making changes.",[468,1307,1308],{},"Use this for:",[892,1310,1311,1314,1317],{},[895,1312,1313],{},"Complex features (plan first, code later)",[895,1315,1316],{},"Risky refactors (review the plan, approve, then build)",[895,1318,1319],{},"Learning how OpenCode would solve it",[468,1321,1322,589],{},[471,1323,1324],{},"Example",[484,1326,1329],{"className":1327,"code":1328,"language":1022},[1020],"I want to add soft delete support to notes. \nUsers should see a deleted notes recovery screen.\nThey can undelete or permanently delete from there.\n",[491,1330,1328],{"__ignoreMap":489},[468,1332,1333],{},"OpenCode responds with a detailed plan:",[484,1335,1338],{"className":1336,"code":1337,"language":1022},[1020],"Plan:\n1. Add `deletedAt` timestamp to notes table\n2. Update queries to exclude soft-deleted notes\n3. Create new recovery screen component\n4. Add restore/permanent delete endpoints\n",[491,1339,1337],{"__ignoreMap":489},[580,1341,1343],{"id":1342},"mode-2-build-mode-tab-key-again","Mode 2: Build Mode (Tab key again)",[468,1345,1346],{},"In Build Mode, OpenCode makes actual code changes.",[468,1348,1349,1351],{},[471,1350,1324],{}," (continuing from plan):",[484,1353,1356],{"className":1354,"code":1355,"language":1022},[1020],"Looks good! Go ahead and implement it.\n",[491,1357,1355],{"__ignoreMap":489},[468,1359,1360],{},"Or for simple changes, skip planning:",[484,1362,1365],{"className":1363,"code":1364,"language":1022},[1020],"Add form validation to the email field in AuthComponent.\nMatch the pattern used in PasswordField.\n",[491,1366,1364],{"__ignoreMap":489},[476,1368],{},[479,1370,1372],{"id":1371},"usage-examples","Usage Examples",[580,1374,1376],{"id":1375},"example-1-explain-existing-code","Example 1: Explain Existing Code",[484,1378,1381],{"className":1379,"code":1380,"language":1022},[1020],"How is authentication handled in src/api/middleware.ts?\nWhat are the security assumptions?\n",[491,1382,1380],{"__ignoreMap":489},[468,1384,1385],{},"OpenCode will:",[892,1387,1388,1391,1394,1397],{},[895,1389,1390],{},"Analyze the file",[895,1392,1393],{},"Explain the authentication flow",[895,1395,1396],{},"Identify potential issues",[895,1398,1399],{},"Suggest improvements",[580,1401,1403],{"id":1402},"example-2-add-a-feature-with-planning","Example 2: Add a Feature (With Planning)",[484,1405,1408],{"className":1406,"code":1407,"language":1022},[1020],"/plan-mode\n",[491,1409,1407],{"__ignoreMap":489},[468,1411,1412],{},"Then:",[484,1414,1417],{"className":1415,"code":1416,"language":1022},[1020],"Add a rate limiter to the API endpoints.\n- Limit to 100 requests per minute per IP\n- Return 429 with Retry-After header\n- Exclude health check endpoints\n",[491,1418,1416],{"__ignoreMap":489},[468,1420,1421],{},"OpenCode creates a plan. Review it, ask follow-ups:",[484,1423,1426],{"className":1424,"code":1425,"language":1022},[1020],"Can you make it configurable in environment variables?\nShould we also rate limit by API key in addition to IP?\n",[491,1427,1425],{"__ignoreMap":489},[468,1429,1430],{},"Once happy, switch to build mode:",[484,1432,1435],{"className":1433,"code":1434,"language":1022},[1020],"/build-mode\nImplement the plan.\n",[491,1436,1434],{"__ignoreMap":489},[580,1438,1440],{"id":1439},"example-3-refactor-with-confidence","Example 3: Refactor with Confidence",[484,1442,1445],{"className":1443,"code":1444,"language":1022},[1020],"Refactor the processOrder function to use async/await\ninstead of promise chains. Keep the same error handling.\n",[491,1446,1444],{"__ignoreMap":489},[468,1448,1449],{},"OpenCode:",[892,1451,1452,1455,1458,1461],{},[895,1453,1454],{},"Suggests refactoring approach",[895,1456,1457],{},"Shows before/after code",[895,1459,1460],{},"Ensures error handling is preserved",[895,1462,1463],{},"Updates any dependent functions",[580,1465,1467],{"id":1466},"example-4-fix-a-bug","Example 4: Fix a Bug",[484,1469,1472],{"className":1470,"code":1471,"language":1022},[1020],"Error: TypeError: Cannot read property 'id' of undefined\nin pages/settings.js line 42\n\nCan you find the root cause and fix it?\n",[491,1473,1471],{"__ignoreMap":489},[468,1475,1476],{},"OpenCode analyzes the error, finds the issue, proposes a fix.",[580,1478,1480],{"id":1479},"example-5-share-your-work","Example 5: Share Your Work",[484,1482,1485],{"className":1483,"code":1484,"language":1022},[1020],"/share\n",[491,1486,1484],{"__ignoreMap":489},[468,1488,1489,1490],{},"OpenCode generates a URL like ",[491,1491,1492],{},"https://opencode.ai/s/abc123xyz",[468,1494,1495],{},"Share this with your team for:",[892,1497,1498,1501,1504,1507],{},[895,1499,1500],{},"Code review",[895,1502,1503],{},"Documentation",[895,1505,1506],{},"Pair programming",[895,1508,1509],{},"Debugging help",[476,1511],{},[479,1513,1515],{"id":1514},"configuration","Configuration",[580,1517,1519],{"id":1518},"agentsmd-project-config","AGENTS.md (Project Config)",[468,1521,1522,1523,1525,1526,1528],{},"After ",[491,1524,1183],{},", you have an ",[491,1527,1096],{}," file that looks like:",[484,1530,1534],{"className":1531,"code":1532,"language":1533,"meta":489,"style":489},"language-markdown shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","# Project: MyApp\n\n## Overview\nFull-stack TypeScript application using Next.js and PostgreSQL.\n\n## Tech Stack\n- **Runtime**: Node.js 18+\n- **Frontend**: React 18 with Next.js 13\n- **Backend**: Next.js API routes\n- **Database**: PostgreSQL with Prisma ORM\n\n## Project Structure\n","markdown",[491,1535,1536,1541,1545,1550,1555,1559,1564,1569,1574,1580,1586,1591],{"__ignoreMap":489},[494,1537,1538],{"class":496,"line":497},[494,1539,1540],{},"# Project: MyApp\n",[494,1542,1543],{"class":496,"line":504},[494,1544,529],{"emptyLinePlaceholder":528},[494,1546,1547],{"class":496,"line":525},[494,1548,1549],{},"## Overview\n",[494,1551,1552],{"class":496,"line":532},[494,1553,1554],{},"Full-stack TypeScript application using Next.js and PostgreSQL.\n",[494,1556,1557],{"class":496,"line":538},[494,1558,529],{"emptyLinePlaceholder":528},[494,1560,1561],{"class":496,"line":553},[494,1562,1563],{},"## Tech Stack\n",[494,1565,1566],{"class":496,"line":558},[494,1567,1568],{},"- **Runtime**: Node.js 18+\n",[494,1570,1571],{"class":496,"line":564},[494,1572,1573],{},"- **Frontend**: React 18 with Next.js 13\n",[494,1575,1577],{"class":496,"line":1576},9,[494,1578,1579],{},"- **Backend**: Next.js API routes\n",[494,1581,1583],{"class":496,"line":1582},10,[494,1584,1585],{},"- **Database**: PostgreSQL with Prisma ORM\n",[494,1587,1589],{"class":496,"line":1588},11,[494,1590,529],{"emptyLinePlaceholder":528},[494,1592,1594],{"class":496,"line":1593},12,[494,1595,1596],{},"## Project Structure\n",[468,1598,1599],{},"src/\n├── api/          # Backend handlers\n├── components/   # React components\n├── pages/        # Next.js pages\n└── utils/        # Shared utilities",[484,1601,1604],{"className":1602,"code":1603,"language":1022},[1020],"\n## Coding Standards\n- TypeScript with strict mode\n- ESLint configured\n- Prettier for formatting\n- Functional components (no class components)\n- Error handling with try/catch\n\n## Key Files\n- `tsconfig.json` - TypeScript config\n- `next.config.js` - Next.js config\n- `.eslintrc.json` - Linting rules\n- `prisma/schema.prisma` - Database schema\n\n## Build & Deploy\n- `npm install` - Install dependencies\n- `npm run dev` - Local development\n- `npm run build` - Production build\n- `npm run test` - Run tests\n- `npm run lint` - Check code style\n\n## Important URLs\n- Local dev: http://localhost:3000\n- Staging: https://staging.example.com\n- Production: https://example.com\n",[491,1605,1603],{"__ignoreMap":489},[468,1607,1608],{},"OpenCode reads this before every conversation, so it always understands your stack.",[580,1610,1612],{"id":1611},"opencoderc-cli-config",".opencoderc (CLI Config)",[468,1614,1615,1616,1619],{},"Create a ",[491,1617,1618],{},".opencoderc"," file in your home directory for global settings:",[484,1621,1625],{"className":1622,"code":1623,"language":1624,"meta":489,"style":489},"language-json shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","{\n  \"defaultModel\": \"claude-opus\",\n  \"defaultProvider\": \"anthropic\",\n  \"theme\": \"nord\",\n  \"editorKeymap\": \"vim\"\n}\n","json",[491,1626,1627,1632,1657,1677,1697,1716],{"__ignoreMap":489},[494,1628,1629],{"class":496,"line":497},[494,1630,1631],{"class":518},"{\n",[494,1633,1634,1637,1641,1644,1646,1649,1652,1654],{"class":496,"line":504},[494,1635,1636],{"class":518},"  \"",[494,1638,1640],{"class":1639},"spNyl","defaultModel",[494,1642,1643],{"class":518},"\"",[494,1645,589],{"class":518},[494,1647,1648],{"class":518}," \"",[494,1650,1651],{"class":511},"claude-opus",[494,1653,1643],{"class":518},[494,1655,1656],{"class":518},",\n",[494,1658,1659,1661,1664,1666,1668,1670,1673,1675],{"class":496,"line":525},[494,1660,1636],{"class":518},[494,1662,1663],{"class":1639},"defaultProvider",[494,1665,1643],{"class":518},[494,1667,589],{"class":518},[494,1669,1648],{"class":518},[494,1671,1672],{"class":511},"anthropic",[494,1674,1643],{"class":518},[494,1676,1656],{"class":518},[494,1678,1679,1681,1684,1686,1688,1690,1693,1695],{"class":496,"line":532},[494,1680,1636],{"class":518},[494,1682,1683],{"class":1639},"theme",[494,1685,1643],{"class":518},[494,1687,589],{"class":518},[494,1689,1648],{"class":518},[494,1691,1692],{"class":511},"nord",[494,1694,1643],{"class":518},[494,1696,1656],{"class":518},[494,1698,1699,1701,1704,1706,1708,1710,1713],{"class":496,"line":538},[494,1700,1636],{"class":518},[494,1702,1703],{"class":1639},"editorKeymap",[494,1705,1643],{"class":518},[494,1707,589],{"class":518},[494,1709,1648],{"class":518},[494,1711,1712],{"class":511},"vim",[494,1714,1715],{"class":518},"\"\n",[494,1717,1718],{"class":496,"line":553},[494,1719,1720],{"class":518},"}\n",[476,1722],{},[479,1724,1726],{"id":1725},"terminal-setup","Terminal Setup",[580,1728,1730],{"id":1729},"recommended-terminal-wezterm","Recommended Terminal: WezTerm",[468,1732,1733],{},"WezTerm works great with OpenCode on all platforms. Here's a basic config:",[484,1735,1739],{"className":1736,"code":1737,"language":1738,"meta":489,"style":489},"language-lua shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","-- ~/.wezterm/wezterm.lua\nlocal wezterm = require 'wezterm'\n\nreturn {\n  font = wezterm.font('JetBrains Mono'),\n  font_size = 12,\n  color_scheme = 'Nord',\n  \n  -- Enable kitty graphics protocol\n  enable_kitty_graphics = true,\n  \n  -- Window padding for readability\n  window_padding = {\n    left = 2,\n    right = 2,\n    top = 2,\n    bottom = 2,\n  },\n}\n","lua",[491,1740,1741,1746,1751,1755,1760,1765,1770,1775,1780,1785,1790,1794,1799,1805,1811,1817,1823,1829,1835],{"__ignoreMap":489},[494,1742,1743],{"class":496,"line":497},[494,1744,1745],{},"-- ~/.wezterm/wezterm.lua\n",[494,1747,1748],{"class":496,"line":504},[494,1749,1750],{},"local wezterm = require 'wezterm'\n",[494,1752,1753],{"class":496,"line":525},[494,1754,529],{"emptyLinePlaceholder":528},[494,1756,1757],{"class":496,"line":532},[494,1758,1759],{},"return {\n",[494,1761,1762],{"class":496,"line":538},[494,1763,1764],{},"  font = wezterm.font('JetBrains Mono'),\n",[494,1766,1767],{"class":496,"line":553},[494,1768,1769],{},"  font_size = 12,\n",[494,1771,1772],{"class":496,"line":558},[494,1773,1774],{},"  color_scheme = 'Nord',\n",[494,1776,1777],{"class":496,"line":564},[494,1778,1779],{},"  \n",[494,1781,1782],{"class":496,"line":1576},[494,1783,1784],{},"  -- Enable kitty graphics protocol\n",[494,1786,1787],{"class":496,"line":1582},[494,1788,1789],{},"  enable_kitty_graphics = true,\n",[494,1791,1792],{"class":496,"line":1588},[494,1793,1779],{},[494,1795,1796],{"class":496,"line":1593},[494,1797,1798],{},"  -- Window padding for readability\n",[494,1800,1802],{"class":496,"line":1801},13,[494,1803,1804],{},"  window_padding = {\n",[494,1806,1808],{"class":496,"line":1807},14,[494,1809,1810],{},"    left = 2,\n",[494,1812,1814],{"class":496,"line":1813},15,[494,1815,1816],{},"    right = 2,\n",[494,1818,1820],{"class":496,"line":1819},16,[494,1821,1822],{},"    top = 2,\n",[494,1824,1826],{"class":496,"line":1825},17,[494,1827,1828],{},"    bottom = 2,\n",[494,1830,1832],{"class":496,"line":1831},18,[494,1833,1834],{},"  },\n",[494,1836,1838],{"class":496,"line":1837},19,[494,1839,1720],{},[476,1841],{},[479,1843,1845],{"id":1844},"tips-tricks","Tips & Tricks",[580,1847,1849],{"id":1848},"tip-1-provide-good-context","Tip 1: Provide Good Context",[468,1851,1852],{},"The better your prompt, the better OpenCode's response:",[468,1854,1855],{},"❌ Bad:",[484,1857,1860],{"className":1858,"code":1859,"language":1022},[1020],"Fix the bug in authentication.\n",[491,1861,1859],{"__ignoreMap":489},[468,1863,1864],{},"✅ Good:",[484,1866,1869],{"className":1867,"code":1868,"language":1022},[1020],"Users can't log in with Google OAuth. \nError: \"redirect_uri_mismatch\"\nThe OAuth config is in src/config/oauth.ts.\nCheck what the redirect URI should be.\n",[491,1870,1868],{"__ignoreMap":489},[580,1872,1874],{"id":1873},"tip-2-use-images","Tip 2: Use Images",[468,1876,1877],{},"Drag/drop a screenshot or design image into OpenCode:",[484,1879,1882],{"className":1880,"code":1881,"language":1022},[1020],"Implement a UI component matching this design:\n[drag image here]\n",[491,1883,1881],{"__ignoreMap":489},[580,1885,1887],{"id":1886},"tip-3-reference-files-explicitly","Tip 3: Reference Files Explicitly",[468,1889,1890,1891,1894],{},"OpenCode understands ",[491,1892,1893],{},"@filename"," references:",[484,1896,1899],{"className":1897,"code":1898,"language":1022},[1020],"Look at @src/utils/auth.ts and implement similar logic \nin @src/utils/api.ts\n",[491,1900,1898],{"__ignoreMap":489},[580,1902,1904],{"id":1903},"tip-4-ask-for-plans-first","Tip 4: Ask for Plans First",[468,1906,1907],{},"For complex work, always ask for a plan:",[484,1909,1912],{"className":1910,"code":1911,"language":1022},[1020],"How would you implement infinite scroll pagination\nin this infinite list component?\n",[491,1913,1911],{"__ignoreMap":489},[468,1915,1916],{},"Review, iterate, then ask it to implement.",[580,1918,1920],{"id":1919},"tip-5-undoredo-safely","Tip 5: Undo/Redo Safely",[468,1922,1923],{},"Not happy with changes? No problem:",[484,1925,1928],{"className":1926,"code":1927,"language":1022},[1020],"/undo\n",[491,1929,1927],{"__ignoreMap":489},[468,1931,1932],{},"Tweak your prompt and try again:",[484,1934,1937],{"className":1935,"code":1936,"language":1022},[1020],"/redo\n",[491,1938,1936],{"__ignoreMap":489},[476,1940],{},[479,1942,1944],{"id":1943},"troubleshooting","Troubleshooting",[580,1946,1948],{"id":1947},"terminal-doesnt-support-kitty-graphics","\"Terminal doesn't support kitty graphics\"",[468,1950,1951],{},"OpenCode will fall back to text-only output. Update your terminal:",[892,1953,1954,1957,1960],{},[895,1955,1956],{},"WezTerm: Latest version",[895,1958,1959],{},"Alacritty: Latest version",[895,1961,1962],{},"Or switch to Ghostty/Kitty",[580,1964,1966],{"id":1965},"api-key-invalid","\"API key invalid\"",[484,1968,1970],{"className":1969,"code":1021,"language":1022},[1020],[491,1971,1021],{"__ignoreMap":489},[468,1973,1974],{},"Re-enter your API key. Check that:",[892,1976,1977,1980,1983],{},[895,1978,1979],{},"You copied the full key (no spaces)",[895,1981,1982],{},"The key has the right permissions",[895,1984,1985],{},"You're using the correct provider URL",[580,1987,1989],{"id":1988},"agentsmd-not-found","\"AGENTS.md not found\"",[484,1991,1993],{"className":1992,"code":1088,"language":1022},[1020],[491,1994,1088],{"__ignoreMap":489},[468,1996,1997],{},"OpenCode will create it. It needs to understand your project structure.",[580,1999,2001],{"id":2000},"changes-arent-applying","\"Changes aren't applying\"",[468,2003,2004,2005,2008,2009,2011],{},"Check that you're in ",[471,2006,2007],{},"Build Mode"," (not Plan Mode). Press ",[491,2010,1147],{}," to toggle.",[476,2013],{},[479,2015,2017],{"id":2016},"integration-with-your-tools","Integration with Your Tools",[580,2019,2021],{"id":2020},"git-opencode","Git + OpenCode",[468,2023,2024],{},"OpenCode commits are normal git commits:",[484,2026,2028],{"className":486,"code":2027,"language":488,"meta":489,"style":489},"git log --oneline\n# Shows OpenCode's commits alongside human commits\n",[491,2029,2030,2040],{"__ignoreMap":489},[494,2031,2032,2034,2037],{"class":496,"line":497},[494,2033,836],{"class":507},[494,2035,2036],{"class":511}," log",[494,2038,2039],{"class":511}," --oneline\n",[494,2041,2042],{"class":496,"line":504},[494,2043,2044],{"class":500},"# Shows OpenCode's commits alongside human commits\n",[468,2046,2047],{},"Always review before pushing:",[484,2049,2051],{"className":486,"code":2050,"language":488,"meta":489,"style":489},"git diff HEAD~1\ngit push  # After review\n",[491,2052,2053,2063],{"__ignoreMap":489},[494,2054,2055,2057,2060],{"class":496,"line":497},[494,2056,836],{"class":507},[494,2058,2059],{"class":511}," diff",[494,2061,2062],{"class":511}," HEAD~1\n",[494,2064,2065,2067,2070],{"class":496,"line":504},[494,2066,836],{"class":507},[494,2068,2069],{"class":511}," push",[494,2071,2072],{"class":500},"  # After review\n",[580,2074,2076],{"id":2075},"github-opencode","GitHub + OpenCode",[2078,2079,2080,2083,2086,2089],"ol",{},[895,2081,2082],{},"OpenCode makes commits to your branch",[895,2084,2085],{},"You push to GitHub",[895,2087,2088],{},"Create a PR for human review",[895,2090,2091],{},"Merge after approval",[580,2093,2095],{"id":2094},"linear-opencode","Linear + OpenCode",[2078,2097,2098,2101,2110,2113,2116],{},[895,2099,2100],{},"Create a well-scoped Linear issue with acceptance criteria",[895,2102,2103,2104],{},"Ask OpenCode to implement it:\n",[484,2105,2108],{"className":2106,"code":2107,"language":1022},[1020],"Implement Linear issue RFX-40:\n[paste acceptance criteria]\nContext files: [list relevant files]\n",[491,2109,2107],{"__ignoreMap":489},[895,2111,2112],{},"Review the changes",[895,2114,2115],{},"Push to GitHub",[895,2117,2118],{},"GitHub/Linear integration auto-updates the issue",[476,2120],{},[479,2122,2124],{"id":2123},"pricing","Pricing",[892,2126,2127,2133,2138],{},[895,2128,2129,2132],{},[471,2130,2131],{},"Free",": Local models (Ollama) or community models",[895,2134,2135,2137],{},[471,2136,1034],{},": Pre-tested models (small fee or free trial)",[895,2139,2140,2142],{},[471,2141,944],{},": You pay the LLM provider (OpenAI, Anthropic, etc.)",[468,2144,2145],{},"No vendor lock-in. You control your data and costs.",[476,2147],{},[479,2149,2151],{"id":2150},"privacy-data","Privacy & Data",[892,2153,2154,2157,2160,2163,2166],{},[895,2155,2156],{},"✅ Code never stored on OpenCode servers",[895,2158,2159],{},"✅ Works with air-gapped/self-hosted models",[895,2161,2162],{},"✅ All context stays local until sent to your chosen LLM",[895,2164,2165],{},"✅ Share links are read-only snapshots",[895,2167,2168],{},"✅ No telemetry by default",[476,2170],{},[479,2172,2174],{"id":2173},"resources","Resources",[892,2176,2177,2187,2196,2204,2213],{},[895,2178,2179,2182,2183],{},[471,2180,2181],{},"GitHub",": ",[911,2184,2185],{"href":2185,"rel":2186},"https://github.com/anomalyco/opencode",[915],[895,2188,2189,2182,2192],{},[471,2190,2191],{},"Docs",[911,2193,2194],{"href":2194,"rel":2195},"https://opencode.ai/docs",[915],[895,2197,2198,2182,2201],{},[471,2199,2200],{},"Models Directory",[911,2202,985],{"href":985,"rel":2203},[915],[895,2205,2206,2182,2209],{},[471,2207,2208],{},"Zen (Curated Models)",[911,2210,2211],{"href":2211,"rel":2212},"https://opencode.ai/zen",[915],[895,2214,2215,2182,2218],{},[471,2216,2217],{},"Discord",[911,2219,2220],{"href":2220,"rel":2221},"https://discord.gg/opencode",[915],[476,2223],{},[479,2225,2227],{"id":2226},"next-steps","Next Steps",[2078,2229,2230,2238,2251,2263,2269],{},[895,2231,2232,2182,2235],{},[471,2233,2234],{},"Install",[491,2236,2237],{},"npm install -g opencode-ai",[895,2239,2240,2243,2244,2247,2248,2250],{},[471,2241,2242],{},"Configure",": Run ",[491,2245,2246],{},"opencode"," → ",[491,2249,1193],{}," → choose provider",[895,2252,2253,2182,2256,2247,2259,2247,2261],{},[471,2254,2255],{},"Initialize",[491,2257,2258],{},"cd ~/project",[491,2260,2246],{},[491,2262,1183],{},[895,2264,2265,2268],{},[471,2266,2267],{},"Try it",": Ask OpenCode to explain your codebase",[895,2270,2271,2274,2275],{},[471,2272,2273],{},"Learn",": Read the full ",[911,2276,2278],{"href":2194,"rel":2277},[915],"docs",[476,2280],{},[468,2282,2283,2286],{},[471,2284,2285],{},"OpenCode in one sentence",": Open source, privacy-first, terminal-native AI coding agent that pairs well with Linear, GitHub, and your favorite editor.",[2288,2289,2290],"style",{},"html pre.shiki code .sHwdD, html code.shiki .sHwdD{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic}html pre.shiki code .sBMFI, html code.shiki .sBMFI{--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B}html pre.shiki code .sfazB, html code.shiki .sfazB{--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D}html pre.shiki code .sMK4o, html code.shiki .sMK4o{--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .s2Zo4, html code.shiki .s2Zo4{--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF}html pre.shiki code .spNyl, html code.shiki .spNyl{--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA}",{"title":489,"searchDepth":504,"depth":504,"links":2292},[2293,2294,2300,2304,2310,2316,2320,2327,2331,2334,2341,2347,2352,2353,2354,2355],{"id":481,"depth":504,"text":482},{"id":577,"depth":504,"text":578,"children":2295},[2296,2297,2298,2299],{"id":582,"depth":525,"text":583},{"id":647,"depth":525,"text":648},{"id":739,"depth":525,"text":59},{"id":825,"depth":525,"text":826},{"id":882,"depth":504,"text":883,"children":2301},[2302,2303],{"id":886,"depth":525,"text":887},{"id":943,"depth":525,"text":944},{"id":992,"depth":504,"text":993,"children":2305},[2306,2307,2308,2309],{"id":996,"depth":525,"text":997},{"id":1012,"depth":525,"text":1013},{"id":1061,"depth":525,"text":1062},{"id":1100,"depth":525,"text":1101},{"id":1115,"depth":504,"text":1116,"children":2311},[2312,2313,2314,2315],{"id":1119,"depth":525,"text":1120},{"id":1163,"depth":525,"text":1164},{"id":1209,"depth":525,"text":1210},{"id":1255,"depth":525,"text":1256},{"id":1293,"depth":504,"text":1294,"children":2317},[2318,2319],{"id":1297,"depth":525,"text":1298},{"id":1342,"depth":525,"text":1343},{"id":1371,"depth":504,"text":1372,"children":2321},[2322,2323,2324,2325,2326],{"id":1375,"depth":525,"text":1376},{"id":1402,"depth":525,"text":1403},{"id":1439,"depth":525,"text":1440},{"id":1466,"depth":525,"text":1467},{"id":1479,"depth":525,"text":1480},{"id":1514,"depth":504,"text":1515,"children":2328},[2329,2330],{"id":1518,"depth":525,"text":1519},{"id":1611,"depth":525,"text":1612},{"id":1725,"depth":504,"text":1726,"children":2332},[2333],{"id":1729,"depth":525,"text":1730},{"id":1844,"depth":504,"text":1845,"children":2335},[2336,2337,2338,2339,2340],{"id":1848,"depth":525,"text":1849},{"id":1873,"depth":525,"text":1874},{"id":1886,"depth":525,"text":1887},{"id":1903,"depth":525,"text":1904},{"id":1919,"depth":525,"text":1920},{"id":1943,"depth":504,"text":1944,"children":2342},[2343,2344,2345,2346],{"id":1947,"depth":525,"text":1948},{"id":1965,"depth":525,"text":1966},{"id":1988,"depth":525,"text":1989},{"id":2000,"depth":525,"text":2001},{"id":2016,"depth":504,"text":2017,"children":2348},[2349,2350,2351],{"id":2020,"depth":525,"text":2021},{"id":2075,"depth":525,"text":2076},{"id":2094,"depth":525,"text":2095},{"id":2123,"depth":504,"text":2124},{"id":2150,"depth":504,"text":2151},{"id":2173,"depth":504,"text":2174},{"id":2226,"depth":504,"text":2227},"OpenCode is a full-featured AI coding agent available as a command-line tool, with optional IDE and desktop integrations. It's built on Node.js and works on macOS, Linux, and Windows.","md",null,{},{"title":455,"description":2356},"PTyoaZELEPm0CgSfEhPA1zYxjGl0OA0OijQTARp_oUs",[2363,2358],{"title":446,"path":447,"stem":448,"description":2364,"icon":400,"children":-1},"Steven Pressfield's 7 rules for crushing resistance and shipping creative work.",1775772887092]