vibeyard
CLAUDE.md1.4k starsChanged 6 months agoMITView on GitHub
A terminal-centric IDE desktop app built on Electron that wraps CLI tool sessions. Users manage projects and sessions, each backed by a PTY running a CLI tool (currently Claude Code, with an abstraction layer for future providers like Copilot CLI and Gemini CLI), rendered via xterm.js. No hot reload — changes require rebuild + app restart. Requires Node v24 (see .nvmrc). No lint tooling is configured. Cross-platform: builds and runs on macOS, Linux, and Windows. Release artifacts (via electron-builder) include…
- Reads credentials
Trending
Quiet since September.thin dataabout the whole repository
Who's talking about elirantutia/vibeyard
- A Hacker News story“Show HN: Vibeyard – An open-source IDE for managing AI coding agents”Hacker News · Apr 23, 2026 · 2 points
- @beyondthecode.bsky.social“🧠 Vibeyard is an open-source IDE designed for managing AI coding agents. The tool provides an interface …”Bluesky · Apr 23, 2026 · 1 likes
- hesreallyhim/awesome-claude-code“[Resource]: Vibeyard - The IDE built for AI coding agents”GitHub · Apr 2, 2026 · 1 reactions
- AppImage/appimage.github.io“Add Vibeyard”GitHub · Sep 29, 2026
- sudosubin/agents.nix“agent-skills.github.elirantutia.vibeyard: init at 0.3.8”GitHub · Sep 27, 2026
The biggest 5 of 8 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 8
Talked about on GitHub, Hacker News and Bluesky (8 times).
On GitHub · 6
- Apr 2, 2026[Resource]: Vibeyard - The IDE built for AI coding agents — hesreallyhim/awesome-claude-code1 reaction · 1 comment
- Sep 29, 2026Add Vibeyard — AppImage/appimage.github.io0 reactions · 1 comment
- Sep 27, 2026agent-skills.github.elirantutia.vibeyard: init at 0.3.8 — sudosubin/agents.nix0 reactions
- Apr 12, 2026add web element info -> prompt integration — debuglebowski/slayzone0 reactions · 1 comment
- Apr 2, 2026Add Vibeyard to Local Apps — filipecalegario/awesome-vibe-coding0 reactions
1 more on GitHub
- Apr 2, 2026New agent interface proposal — no-fluff/awesome-vibe-coding0 reactions
On Hacker News · 1
- Apr 23, 2026Show HN: Vibeyard – An open-source IDE for managing AI coding agents2 points
On Bluesky · 1
- Apr 23, 2026🧠 Vibeyard is an open-source IDE designed for managing AI coding agents. The tool provides an interface for configuring and monitoring… — @beyondthecode.bsky.social1 likes and repost
In this repository2 other files it gives its agents.
- add-npm-dependencySkill
- ui-devSkill
The file
We split this CLAUDE.md into the rules it gives an agent
10 rules. About 0 are common, 4 are distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 16
No hot reload — changes require rebuild + app restart.
- Very specific: line 32
Test files are excluded from production builds via exclude in tsconfig.main.json and tsconfig.renderer.json.
- Very specific: line 101
When asserting on a path that the implementation produced via path.join, path.resolve, or path.normalize, never hardcode forward-slash …
- Very specific: line 132
When working on renderer/UI code, the /ui-dev skill is automatically invoked.
- Distinctive: line 140
After completing an implementation task, always:
- Very specific: line 142
Run /code-review to review changed code for correctness bugs and reuse/quality/efficiency cleanups.
- Very specific: line 143
Run /simplify to apply reuse, simplification, efficiency, and altitude cleanups to the changed code.
- Distinctive: line 144
Add or update tests as needed to cover the changes.
- Very specific: line 148
Always use the /commit command when committing changes to this project.
- Distinctive: line 150
Never commit, push, or create pull requests unless the user explicitly asks for it.
≈ “Common” is an estimate: at least 1 in 5 of the 12,729 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
What This Is
A terminal-centric IDE desktop app built on Electron that wraps CLI tool sessions. Users manage projects and sessions, each backed by a PTY running a CLI tool (currently Claude Code, with an abstraction layer for future providers like Copilot CLI and Gemini CLI), rendered via xterm.js.
Build & Run
npm run build # Compile all three targets (main, preload, renderer) + copy assets
npm start # Build then launch Electron app (alias: npm run dev)No hot reload — changes require rebuild + app restart.
Requires Node v24 (see .nvmrc). No lint tooling is configured.
Cross-platform: builds and runs on macOS, Linux, and Windows. Release artifacts (via electron-builder) include .dmg/.zip (mac), .deb/.AppImage (linux), and NSIS installer + portable .exe (win). CI covers all three platforms.
Testing
npm test # Run all tests once
npm run test:watch # Watch mode (re-runs on file changes)
npm run test:coverage # Run with coverage report (terminal + HTML)Uses Vitest with v8 coverage. Tests are co-located with source files as *.test.ts. Coverage HTML report outputs to coverage/index.html.
Test files are excluded from production builds via exclude in tsconfig.main.json and tsconfig.renderer.json.
Three renderer modules (session-cost.ts, session-activity.ts, session-context.ts) expose _resetForTesting() to clear module-level state between tests. Main process tests mock fs, child_process, node-pty, and os via vi.mock().
Architecture
Three-process Electron architecture with strict context isolation:
- Main process (
src/main/) — Node.js side: window creation, PTY lifecycle vianode-pty, filesystem access, persistent state (~/.vibeyard/state.json). IPC handlers inipc-handlers.tsdispatch topty-manager.tsandstore.ts. CLI tool behavior is abstracted via the provider system (src/main/providers/). - Preload (
src/preload/preload.ts) — Secure bridge exposingwindow.vibeyardAPI viacontextBridgewith namespaces:pty,session,store,profiles,fs,provider,menu. - Renderer (
src/renderer/) — Vanilla TypeScript DOM UI (no framework).AppStatesingleton instate.tsuses an event emitter pattern; components incomponents/subscribe to state changes.
Data Flow
Renderer → IPC invoke/send → Main process → PTY/filesystem → IPC send back → Renderer updates xterm terminal.
Build Targets
Each process has its own tsconfig.*.json. Main and preload compile via tsc (CommonJS). Renderer bundles via esbuild (IIFE format, browser platform, with sourcemaps).
CLI Provider System
CLI-specific behavior is encapsulated behind a CliProvider interface (src/main/providers/provider.ts). Each provider handles binary resolution, env vars, args, hooks, config reading, and cleanup. Providers are registered in a registry (src/main/providers/registry.ts) at app startup.
- Provider per-session: Each
SessionRecordhas aproviderId(defaults to'claude'). A project can contain sessions from multiple providers. - Capabilities pattern: Providers declare what they support via
CliProviderCapabilities. UI can conditionally enable features per-session. - Current providers:
ClaudeProvider(src/main/providers/claude-provider.ts) — extracts all Claude-specific logic frompty-manager.ts,prerequisites.ts,claude-cli.ts, andhook-status.ts. - System prompt:
buildArgsacceptssystemPrompt?: stringand every provider must honor it (used by the Team feature). Claude maps it to--append-system-prompt; Codex to-c developer_instructions=<value>; Copilot/Gemini to--system-prompt. The renderer passes it via the transientpendingSystemPromptfield onSessionRecord, which is consumed once on the first PTY spawn and stripped fromstate.jsonso it is never re-injected on resume. - Profiles (multi-license): a
Profile({ id, name, providerId, configDir, managed }, top-levelstate.profiles) backs a CLI session with an isolated config directory so a user can run separate logins/licenses (work vs personal).buildEnv(sessionId, baseEnv, opts?: { configDir? })injects it — Claude setsCLAUDE_CONFIG_DIR(which relocates everything Claude reads/writes: credentials,settings.json, hooks, status line, transcripts, agents); other providers accept the param but don't use it yet. The effective profile (explicit choice > projectdefaultProfileId>preferences.defaultProfileId, provider-matched) is resolved once at session creation viaresolveProfile(src/renderer/state/specialized-sessions.ts) and pinned ontoSessionRecord.profileId— it is NOT re-derived at spawn, so changing a default later never redirects an existing session's resume. At spawn,split-layout.tslooks up the config dir from the stickysession.profileIdonly (provider-checked) and threads theconfigDirstring throughcreateTerminalPane→pty.create→pty:create→spawnPty→buildEnv.profileIdis persisted onSessionRecord/ArchivedSession(and onTranscriptDescriptor/DeepSearchResultso global-search resume reopens under the right dir);removeProfileclears it from sessions, projects, history, and prefs. BecauseCLAUDE_CONFIG_DIRrelocatessettings.json,spawnPtyinstalls Vibeyard's hooks + status line into the profile dir on each Claude spawn via the config-dir-parameterizedinstallHooksOnly(configDir)/installStatusLine(configDir)inclaude-cli.ts(the status-line script stays global in~/.vibeyard/run/; only per-dirsettings.jsondiffers).getTranscriptPath(cliSessionId, projectPath, configDir?)anddiscoverTranscripts()are profile-aware — the latter unions~/.claude/projectswith every claude profile's<configDir>/projects(read fromloadState()). Managed profile dirs live at~/.vibeyard/profiles/<id>/(auto-created), with an optional custom path; provisioning issrc/main/profiles.tsexposed via theprofiles:provisionIPC. Profile management UI is the Preferences "Profiles" section; selection is in the New Session dialog and the sidebar project "Project Settings…" menu. v1 leavesgetConfig(Overview agents/skills/MCP) and the config-watcher on the default~/.claude. macOS keychain caveat + guardrail: on macOS Claude stores credentials in the system Keychain (not<configDir>/.credentials.json) under a per-config-dir service nameClaude Code-credentials-<first 8 hex of sha256(configDir)>(verified on 2.1.159), so profiles isolate logins only on Claude builds new enough to namespace that entry. Older builds (≤2.1.19, anthropics/claude-code#20553) reuse one sharedClaude Code-credentialsentry, bleeding logins across profiles.src/main/claude-keychain.ts(getKeychainIsolationStatus, exposed via IPCprofiles:keychainStatus→window.vibeyard.profiles.keychainStatus()) guards this: empiricallysupportedif any known profile already has a namespaced Keychain entry, else version-gated (≤2.1.19⇒unsupported; newer-but-unconfirmed ⇒unknown, allowed — never false-blocked); non-macOS is alwayssupported(isolation is file-based). Onunsupported,spawnPtyskips the profile session and writes an in-pane message (it does not throw — the renderer firespty.createun-awaited), and the Preferences "Profiles" section blocks profile creation and shows a warning banner. The shared semver helpers (parseSemver,semverGte) live inclaude-hook-versions.ts. - Agent files: providers expose optional
agentsDir(),installAgent(slug, content), andremoveAgent(slug)methods (default impls delegate tosrc/main/providers/agent-files.ts, which accepts an optional extension — Copilot passes.agent.md; everyone else uses the default.md). Each provider's user-global agents directory is~/.<cli>/agents/(e.g.~/.claude/agents/). The Team feature uses these via theprovider:installAgent/provider:removeAgentIPC channels to mirror aTeamMember(withinstallAsAgent: true) as a<slug>.md(or<slug>.agent.mdfor Copilot) file across every installed provider, making it invokable as/<slug>inside CLI sessions. Slug is sticky on the member (agentSlugfield) so renames preserve the same file. Filename collisions with non-Vibeyard agents at the same slug will overwrite — the renderer only deduplicates within team members.
Key Components
terminal-pane.ts— xterm.js wrapper per session, handles PTY data streaming and WebGL rendering with software fallbackstate.ts— Reactive AppState singleton; debounced persistence (300ms) to~/.vibeyard/state.jsonsplit-layout.ts— Manages tab mode (single terminal) vs split mode (side-by-side)- Renders must not touch pane DOM they don't need to.
renderLayout()runs on everysession-changed/layout-changed, andappendChildon a node that is already a child is a remove-and-reinsert: it blurs whatever is focused inside (the Cmd+F find bar is appended into.terminal-pane, seesearch-bar.ts) and collapses an in-progress selection. So everyattach*ToContainerno-ops whenelement.parentElement === container; DOM order among the panes laid out together is corrected separately byensurePaneOrder(split-layout) via the DOM-freeisInRelativeOrderincomponents/pane-order.ts— relative order, because hidden panes stay in the container interleaved with the visible ones — andrenderSwarmModereuses its.swarm-grid-wrapperinstead of rebuilding it. Focus is guarded one level up, not by sniffing the DOM:setFocusedcannot tell the find bar from the terminal (it is inside the pane), sofocusPanegates the call on the DOM-freeshouldFocusPane(components/pane-focus.ts) — a render that does not change the focused pane never callssetFocusedat all, unless focus is sitting on nothing.fitTerminalskipspty.resizewhen thecolsxrowsmemo is unchanged (a redundant resize makes the CLI redraw under a selection, and xterm doesclearSelection()on a row-count change);spawnTerminalclears that memo and re-fits afterpty.createresolves, because a fit racing the un-awaited spawn is dropped byresizePtyfor a session it has not registered yet (Copilot awaits a hook install first) and the PTY would stay at the 120×30 spawn default. Feeding this loop,updateSessionCliId(state.ts) early-returns on an unchanged id and the statusLine'swrite_if_changedwrites.sessionid/.nameonly on change — the statusLine fires on every render, and each write used to cost a persist plus a full re-render. session-activity.ts— Tracks working/waiting/idle status with debounced transitions- Hook → session-state contract — see
HOOKS.mdfor the full map; it is verified against a specific Claude Code version and must be re-checked against https://code.claude.com/docs/en/hooks whenever hook handling changes. Three points are load-bearing and easy to get wrong. (1)PostToolUsefires only on success; a tool that ran and failed firesPostToolUseFailure(error,is_interrupt,duration_ms), and a call rejected before execution fires neither. Treating any non-emptytool_responseas a failure — which this repo did until the events were re-verified — feeds every successful tool call intomissing-tool-detector.ts. (2) AStopis not always a completion: the main agent fires one every time it pauses on parallel subagents.stop_status_writer.pyresolves it from the payload'sbackground_tasksarray, holdingworkingonly forsubagent/teammate/workflowentries; only a non-empty array is authoritative — an empty one is not proof of an idle session, because the CLI filters that array on anisBackgroundedflag freshly-dispatched subagents don't carry yet — so empty and absent both fall through to the legacy<sid>.subagentscounter.session_cronsis never consulted or a/loopsession would never complete. (3) Every field name inINSPECTOR_FIELDS(claude-cli.ts) must exist in a documented per-event schema, and be read by something. A compile-time assertion againstkeyof InspectorEventcatches the internal half of that drift; the external half — whether Claude Code actually sends the field — no type system can check, and an invented name silently renders a blank timeline row forever (howconfig_key/question/answersurvived for months). Beware nested keys when reading the docs: the Elicitation example'srequested_schema.properties.username.typescans like top-leveltype/usernamefields, and both were added on a previous pass and were dead on arrival. Generated Python embeds values viapyLiteral(shared/python.ts), never a rawr'…'literal, which breaks on an apostrophe in the path. session-cost.ts— Structured cost tracking via Claude CLI status line (statusLinesetting), with regex fallback for older CLI versions. Provides per-session and aggregate cost data (USD, tokens, cache, duration). Both this module andsession-context.tsfeed the terminal pane's status rail (right cluster =profile · model · $cost | in/out, left cluster = the context meter) off the samesession:costDatapayload — Claude's statusLine writes{cost, context_window, model}into one<sid>.costfile; there is no.contextfile. Two things make the rail fragile on restore, and both are load-bearing. (1)setCostData/setContextDatadedupe on unchanged values (the statusLine rewrites.coston every render, and each event costs a persist + re-render), andrestoreCost/restoreContextseed those maps silently from the persistedSessionRecord.cost/.contextWindowat load. A resumed session reports exactly the context that was persisted at quit, so the first post-resume payload is deduped away andonContextChangenever fires — cost only self-heals because its dedupe set includes the tickingtotalDurationMs. (2) The rail's left cluster is built lazily insideupdateContextDisplayand hidden by CSS.context-indicator:empty, so "no event" renders as "no meter", not as a stale one.createTerminalPanetherefore pulls both clusters fromgetCost/getContextright afterinstances.set— the general invariant being that a store with a silentrestore*seeder must be pulled by any consumer that builds its DOM lazily; a push-only consumer is correct only if its DOM provably predates every event. (Every other consumer of these two stores — board cards, the sessions widget,refreshProfileLabels— already pulls, so the pane rail was the lone exception.) The cost pull is unconditional so thatupdateCostDisplaystays the single renderer of.cost-display, painting the$0.0000placeholder itself when cost is null; the pane constructor only toggles.hiddenoff the provider capabilities.ArchivedSessionpersistscostbut nocontextWindow, so resume-from-history still starts both empty- Session auto-naming —
session-title.tsadopts the CLI's own session title as the tab name, so users don't have to rename manually. The title arrives as thesession_namefield of Claude's statusLine stdin payload (the custom name from--name//renamewhen one exists, otherwise Claude's AI-generated topic title; the key is absent until the session has one). Hook payloads carry no title — verified against the 2.1.237 binary, whose base hook schema is{session_id, transcript_path, cwd, prompt_id, permission_mode, agent_id, agent_type, effort}— so the statusLine is the only live source.buildStatusLinePythoninsrc/main/hook-status.tsbuilds one body used on every platform;installStatusLineScriptwrites it to~/.vibeyard/run/statusline.pyand the.sh/.cmdwrapper invokes it by path, never inlined into the shell command (see thehook-commands.tsmodule docstring for why inlining Python here is fragile). It writes<STATUS_DIR>/<sid>.nameas{"name": "…", "session_id": "…"}, keyed onCLAUDE_IDE_SESSION_ID; the watcher forwards it assession:sessionName→applyCliSessionName, which skips sessions withuserRenamed(a Vibeyard rename is sticky and always wins), drops a title whosesession_idno longer matchessession.cliSessionId(a stale.namesurvives/clearuntil the next render, andresyncAllSessionsreplays every file on window activate), and is gated onpreferences.autoTitleEnabled. Three script details are load-bearing: it writes only on change (statusLine fires on every render, and each write costs a persist + full tab-bar re-render) — which is why flippingautoTitleEnabledback on sendssession:resyncStatusto replay every status file, since an unchanged.nameproduces no further fs event andapp.on('activate')is effectively macOS-only; it usesjson.dumpsso a CJK/emoji title is ASCII on disk (a raw write hits Windows' locale codepage, raisesUnicodeEncodeError, and would take the.costwrite down with it); andSTATUS_DIRis embedded viaJSON.stringify, whose escapes are all valid Python ones — a rawr'…'literal breaks on an apostrophe in the path (a Windows user named O'Brien), and aSyntaxErrorthere silently kills cost, context, sessionid and name at once..nameis a provider-facing channel, not Claude-private — any provider can write that file the waycodex-session-watcher.tsalready writes.sessionidwithout hooks; today only Claude does, so non-Claude sessions no longer auto-name (this replaced an approach that scraped Claude's box-drawing chrome out of raw PTY bytes). Default names come fromsrc/renderer/state/session-naming.ts:nextNumberFor(key, project)counts the highest existing number across sessions and history for every locale's template of that i18n key, withnextSessionNumber/defaultSessionNameas theSession {num}wrappers and the MCP inspector tabs numbering independently off the same helper. This replaces three separatelength + 1formulas, which reissued a number already on screen after a middle tab was closed. components/active-sessions-panel.ts— Global, cross-project Active Sessions list rendered into#sidebar-active-sessions(a persistent sidebar block above Discussions).selectActiveSessions(projects, statusOf, activeStatuses)is a DOM-free selector that collects open CLI sessions (isCliSession) acrossappState.projectswhose livegetStatus()is in the configured set, ordered bySTATUS_PRIORITY(fromproject-status.ts, now exported) then project name.initActiveSessions()subscribes tosession-activity.onChange+ the relevantappStateevents and re-renders; rows route clicks throughsetActiveProject+setActiveSession. Visibility is gated bypreferences.sidebarViews.activeSessionsand requires more than one project (with a single project the rows just duplicate its own tab bar); the "active" status set comes frompreferences.activeSessionStatuses({ working, waiting, input, completed }, default working/input/completed viaresolveActiveStatuses). Both preferences are edited in the Preferences → Appearance section. Styles live instyles/sidebar.css; status dots reuse the existing.project-status.<status>classes.components/git-panel.ts— Git changes for the active project, rendered inside its sidebar card as agitpanel-toggle tab (a thirdProjectPanelalongsidehistory/filesinsidebar.ts), not a standalone bottom panel. The "Git" tab carries a.project-action-badgecount of total changes (badge + click-to-open);Cmd/Ctrl+Shift+G(toggleGitPanel, exported fromsidebar.ts) toggles it.mountGitPanel(project, container)reparents a single persistent node into.project-panel-gitso file rows/scroll survive sidebar re-renders;closeGitPanel()detaches it. The sharedloadFiles/worktree-selector logic is unchanged;sidebarViews.gitPanelnow gates the tab button. There is no#git-panelnode inindex.html.browser-tab/— Browser tab pane split into focused modules:types.ts,instance.ts(registry + preload path),navigation.ts,viewport.ts,selector-ui.ts,inspect-mode.ts,flow-recording.ts,flow-picker.ts,session-integration.ts, andpane.ts(DOM build + event wiring).browser-tab-pane.tsis a re-export shim for backward compatibility.board-state.ts— Kanban board CRUD: tasks, columns, tags, reorder. MutatesappState.activeProject.boardin place, callsappState.notifyBoardChanged().board-filter.ts— Module-level search query and tag filter state for the board. Observer pattern viaonFilterChange().board-session-sync.ts— Listens to session lifecycle events and auto-moves board tasks (e.g. to Done on session complete).components/board/— Board UI:board-view.ts(container + header with the search box and "New task" button in a right-aligned actions group, plus a dedicated "Filter" tag row below),board-column.ts(column with header/rename),board-card.ts(card with run/resume/focus),board-task-modal.ts(create/edit dialog with tags),board-dnd.ts(drag-and-drop with injected DOM drop targets),board-context-menu.ts.styles/kanban.css— All kanban board styles including cards, columns, DnD drop targets, tag pills, and filter UI.components/team/— Team tab:instance.ts+pane.ts(tab plumbing mirroring kanban),team-view.ts(header + card grid + empty state),member-card.ts(Chat/Edit/Sessions/Delete actions),member-modal.ts(create/edit form using the sharedshowModal),predefined-picker.ts(fetches suggestions from this repo'spersonas/folder, marks already-installed members),github-fetcher.ts(Contents API + raw download, 1 hour cache),frontmatter.ts(Markdown →TeamMemberparser).styles/team.css— Team grid, cards, predefined-picker dialog. Uses CSS variables only.- Team state lives at the top level of
~/.vibeyard/state.jsonasstate.team.members(global, not per-project). Predefined suggestions cache atstate.team.predefinedCache. Predefined personas live in the top-levelpersonas/directory of this repo and are fetched at runtime via the GitHub Contents API; the location is configured by the single constantTEAM_MEMBERS_REPOinsrc/shared/team-config.ts— flip itsowner/repo/pathto retarget. components/project-tab/— Customizable Overview page driven by a gridstack.js drag-and-drop grid.pane.tsbuilds the toolbar (+ Add Widget,Edit layouttoggle) + grid root.grid.tswraps gridstack and owns tile chrome (header, drag handle, refresh/settings/remove buttons). Per-project layout persists atProjectRecord.overviewLayoutwith widget records{ id, type, x, y, w, h, config? }— lazy-defaulted on first render to mirror the legacy 2-column layout, no migration code. Each widget is aWidgetFactoryregistered inwidgets/widget-registry.ts; current types:readiness,provider-tools(refactors of the old columns),github-prs,github-issues,team(reusescreateMemberCardfromcomponents/team/member-card.ts, listens to'team-changed'),kanban(reusescreateCardElementfromcomponents/board/board-card.ts, groups by column, listens only to'board-changed'— live per-session metrics are intentionally omitted to avoid full-rerender storms; the full kanban tab covers that),sessions(active CLI sessions + recent archived split into two sections; filtered throughisCliSession; click-to-focus callssetActiveSession, click-to-resume callsresumeFromHistory; subscribes tosession-activity/session-cost/session-unreadobservers with surgical row updates for status/cost ticks; settings modal atwidgets/sessions-settings-modal.tswith config inwidgets/sessions-types.tslets users tunerecentLimit),usage-stats(Claude-Code-only summary of sessions/messages/model token usage and a 7-day + by-hour activity heatmap; reads~/.claude/stats-cache.jsonviawindow.vibeyard.stats.getCache(); styled withstyles/usage.css; refresh wired through the widget chrome's refresh button — no in-content button). GitHub widgets usewindow.vibeyard.github.*IPC backed bysrc/main/github-cli.tswhich shells out to the user's localghCLI (auto-detected; PATH is the augmentedgetFullPath()frompty-manager). Repo defaults to the project's git origin viagetGitRemoteUrl; per-widget settings (widgets/github-settings-modal.ts) override repo, state, max items, and refresh interval. Read/unread tracking lives ingithub-unread.ts(Set + observer mirroringsession-unread.ts); per-item lastSeen timestamps persist atProjectRecord.githubLastSeen. The tab-bar surfaces unread by branching onproject-tabto consulthasUnreadInProject. Gridstack CSS is bundled by copyingnode_modules/gridstack/dist/gridstack.min.csstodist/renderer/vendor/(esbuild has no CSS loader);<link>ed fromindex.html.styles/widgets.cssholds shared widget chrome.terminal-context-menu.ts— Right-click context menu for terminal panes (Copy, Paste, Select All). DOM-based using sharedtab-context-menuCSS classes.showTerminalContextMenu()/hideTerminalContextMenu()exports; integrated viacontextmenulistener onxtermWrapinterminal-pane.ts. Every action handler callsterminal.focus()after closing the menu so keyboard input resumes immediately (clicking a menu item otherwise leaves focus on the document, e.g. typing after Paste would be dropped). Note: the flex layout (display:flex; justify-content:space-between; align-items:center) lives on the shared.tab-context-menu-itemselector instyles/tabs.css, so it affects every menu reusing that class — existing single-label items are unaffected sincespace-betweenhas nothing to push.- Opening a file in a tab — every "open this path in a file-reader tab" path goes through
openFileReaderChecked(projectId, filePath, lineNumber?)insrc/renderer/open-file-reader.ts, neverappState.addFileReaderSessiondirectly. The order is load-bearing:addFileReaderSession→attachSessionToProjectappends the tab and setsproject.activeSessionIdbefore anything touches the filesystem, so a stale path (a cmd+clicked path from old terminal output, a deleted file, a dead Markdown link) spawns a tab thatloadFile'scloseSessionIfFileMissingreaps a moment later — andremoveSessionthen falls back to the left neighbour by index, not to the tab the user came from and not toNavHistory, so the user watches a tab flash and lands somewhere arbitrary. The helper therefore validates first with a parallelfs.exists+fs.isDirectory(a directory passesexistsbut reads asEISDIR, and that tab is never reaped — it sticks around showing "Failed to load file"), and re-checks thatprojectIdis still the active project after the await so a mid-flight project switch cannot steal the other project's tab selection. It never rejects and returnsvoid, so callers fire it with a barevoidrather than each repeating a.catch; every failure isconsole.warn-only, matching the other silent-open paths. Callers:terminal-link-provider.ts(cmd+click),file-reader.ts(Markdown links),file-tree.ts,quick-open.ts,provider-tools-widget.ts,top-files-widget.ts. Path normalization is the sharedresolveProjectFilePath(project, filePath)instate/specialized-sessions.ts, used by both the check andaddFileReaderSession, so the two can never disagree about which path they mean.closeSessionIfFileMissingstays as the later, complementary check — it covers a file deleted while its tab is open (including tabs restored fromstate.jsonthat never went through the helper). NoteaddDiffViewerSession(components/file-viewer.ts) still has the unguarded shape. - Rendered-Markdown links —
renderMarkdownContent(content, baseDir?)incomponents/file-reader.tsattaches one delegatedclicklistener to the markdown wrapper that alwayspreventDefault()s, then routes the href through the pure, DOM-freesrc/renderer/markdown-link.ts(resolveMarkdownLink(href, baseDir)→anchor|external|file|ignore).external→window.vibeyard.app.openExternal;file→openFileReaderChecked(see the Opening a file in a tab bullet below);anchor→ scroll to the heading whoseslugifyHeadingtext matches (marked v17 emits no headingids). Every failure pathconsole.warns, since a suppressed default is otherwise indistinguishable from a dead click; cross-file fragments (other.md#section) are stripped — the file opens at the top.renderBodypassesdirname(resolveFilePath(instance))asbaseDir;components/team/predefined-picker.tscalls it with none, and nobaseDirmeans nofiletarget at all — absolute paths included, because that picker renders Markdown fetched over the network andisAllowedReadPathpermits~/.claude.json,~/.claude/, etc. Suppressing the default is load-bearing, not cosmetic: the renderer is afile://document, so an un-intercepted relative.mdlink resolves againstdist/renderer/index.htmland navigates the window off the app, destroying every session and PTY. The main-process backstop iswill-navigateinmain.ts, which now allows only the app document (compared on the decodedpathToFileURLpathname) and blocks everything else includingfile://. Shared helpers introduced for this:resolveRelativePathinsrc/shared/platform.ts(root-aware — a POSIX root, Windows drive, or UNC share is split off as an un-poppable prefix, so..can never turn an absolute path into a relative one thatfs:existswould then resolve against the main-process cwd),slugifyHeadinginsrc/shared/slug.ts(distinct fromnameToSlug— keeps non-latin chars, one dash per whitespace char), andisHttpUrlinsrc/shared/url.ts(used by bothmain.tsand the link router). - i18n — lightweight in-house internationalization (no third-party library).
src/renderer/i18n.tsexportst(key)(dot-path lookup with English fallback +console.warnfor missing keys),getLocale(),setLocale(locale)(unknown locales rejected), andonLocaleChange(cb)returning an unsubscribe handle. Catalogs atsrc/renderer/locales/{en,zh-CN}.jsonare statically imported by esbuild (zero runtime fetches).src/renderer/system-locale.tsresolvesnavigator.language(/^zh/i→zh-CN, elseen). The persisted choice lives atPreferences.locale('en' | 'zh-CN', defined inline insrc/shared/types.tsrather than imported fromi18n.tsto avoid a main↔renderer import cycle). Persistence flows through the existingsetPreference('locale', loc)→ 300ms-debounced main-process save.initI18n()insrc/renderer/index.tsruns right afterappState.load(); on first launch (no savedlocale) it persists the OS-resolved choice. Thepreferences-changedlistener inindex.tscallsi18n.setLocale(newLocale)andrerenderOpenPreferencesModal()(exported fromsrc/renderer/components/preferences-modal.ts) so the open Preferences modal re-translates in place. The Language switcher itself lives at the top of Preferences → General as acreateCustomSelectrow backed byappState.setLocale(live, no Confirm required). Translated sections in v1: Preferences sidebar labels + General + Appearance. Out-of-modal strings (sidebar buttons, tab titles) stay English until a follow-up PR.
Platform Checks
Platform detection is centralized in src/main/platform.ts. Import
isWin/isMac/isLinux (and derived constants pathSep, whichCmd,
pythonBin) from there — do not inline process.platform === 'win32'
or redefine isWin/isMac locally in source or test files. The
three-way managed-path branch in claude-cli.ts is the one intentional
exception.
Cross-platform paths in tests
When asserting on a path that the implementation produced via path.join,
path.resolve, or path.normalize, never hardcode forward-slash literals
like '/repo/foo.ts' in the assertion — they pass on macOS/Linux but fail
on windows-latest because Node yields \repo\foo.ts there. Build the
expected value with the same primitive the implementation uses:
import * as path from 'path';
// good — matches whatever path.join produces on the running platform
expect(mockRm).toHaveBeenCalledWith(path.join('/repo', 'foo.ts'), opts);
// bad — hidden Windows-only failure
expect(mockRm).toHaveBeenCalledWith('/repo/foo.ts', opts);This applies to any assertion on arguments to fs.*, child_process calls,
or anything else that flows a joined path through. CI runs on all three
platforms, so a forward-slash literal will eventually fail on Windows.
File Watching
Live filesystem updates for the file tree, file reader, and diff viewer are backed by a single chokidar watcher in src/main/file-watcher.ts (chokidar is ESM-only but require-able under Electron's Node ≥22.12). It watches directories non-recursively (depth: 0), ref-counted per dir via watchDir(dir) / unwatchDir(dir) (IPC fs:watchDir / fs:unwatchDir). Watching the parent dir — not the file inode — is deliberate: it survives atomic save/replace (write-temp + rename), which silently kills an inode watch. Changes are coalesced and debounced (150ms) into a single batched fs:changed IPC carrying FsChange[] ({ path, dir, type }, type ∈ add/addDir/change/unlink/unlinkDir; see src/shared/types.ts). The renderer subscribes via window.vibeyard.fs.onFsChange. stopAllFileWatchers() is wired into main.ts teardown (window closed + before-quit).
Scope is lazy: only expanded tree folders and the parent dirs of open reader/viewer files are watched (cheap on huge repos). The file tree (file-tree.ts) reacts by incremental reconciliation (reconcileChildren), not full rebuilds: rows are keyed by data-entry-path, vanished entries are removed (unwatching their subtree via unwatchSubtree), new entries are inserted at the sorted position, and unchanged rows — with their expanded subtrees, scroll, and selection — are left untouched. Change bursts are flushed once per requestAnimationFrame. Cross-platform path helpers (dirname, isPathUnder) live in src/shared/platform.ts. Note: this is separate from git-watcher.ts, which watches the whole working tree and emits git:changed for the git-status UI. To avoid the macOS FSEvents teardown storm on project switch (#142), git-watcher.ts uses a single recursive fs.watch on macOS + Windows (watchRecursiveWorkingTree, one OS handle, events filtered via hasIgnoredSegment) and keeps the capped per-dir BFS (walkAndWatch, MAX_WATCHES) on Linux, where recursive fs.watch is unsupported and previously leaked inotify watches (#139). Fine-grained .git watches and the 60s git-status poll are unchanged.
State Persistence
App state (projects, sessions, layout) persists to ~/.vibeyard/state.json via the main process store. Saves are debounced and flushed on quit. Sessions track cliSessionId for CLI session resume capability.
UI Development
When working on renderer/UI code, the /ui-dev skill is automatically invoked. It documents all custom components (dropdowns, modals, alerts, badges), CSS theming variables, styling conventions, and component architecture patterns. Always follow it — never use native <select>, never hardcode colors, always reuse existing components.
Planning
When entering plan mode for a new feature, consider whether the feature (or aspects of it) should be exposed as a user-configurable option in Preferences. If it's relevant, ask the user whether they'd like it added as a config in the prefs before finalizing the plan.
Post-Implementation
After completing an implementation task, always:
- Run
/code-reviewto review changed code for correctness bugs and reuse/quality/efficiency cleanups. Run it automatically — do not ask the user for permission first. - Run
/simplifyto apply reuse, simplification, efficiency, and altitude cleanups to the changed code. Run it automatically — do not ask the user for permission first. - Add or update tests as needed to cover the changes.
Git Workflow
Always use the /commit command when committing changes to this project. Do not create commits manually.
Never commit, push, or create pull requests unless the user explicitly asks for it.
CHANGELOG.md is auto-generated by the release action (via the /release / release-notes flow). Do not edit it as part of coding tasks — changes there will be overwritten at release time.
Maintaining This File
When your changes affect the architecture, build process, key components, data flow, or any other information documented above, update this CLAUDE.md to reflect the new state. This includes adding/removing/renaming files, changing IPC namespaces, modifying the build pipeline, or introducing new patterns. Keep this file accurate so future sessions start with correct context.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

