Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
65 commits
Select commit Hold shift + click to select a range
0f04271
docs(16-pty-backend-foundation): create phase 16 plan — 3 plans, 2 waves
loco1842 May 18, 2026
8ec9a19
feat(16-01): add PTY event constants, register TerminalService, insta…
loco1842 May 19, 2026
e3e55a2
feat(16-01): create TerminalService with Unix PTY lifecycle, Windows …
loco1842 May 19, 2026
c5d6fa4
docs(16-01): complete TerminalService backend foundation plan
loco1842 May 19, 2026
8be8b44
feat(16-02): add readLoop goroutine with 16ms batching and emitOutput
loco1842 May 19, 2026
9a64c68
feat(16-02): add monitorExit goroutine with auto-restart and pty-exit…
loco1842 May 19, 2026
4e25f95
docs(16-02): complete output streaming and exit detection plan
loco1842 May 19, 2026
08bcfa7
test(16-03): add TerminalService test suite with 7 requirement tests
loco1842 May 19, 2026
c8ce92f
docs(16-03): add Windows PTY refactoring TODO — go-winpty deprecated,…
loco1842 May 19, 2026
b199cbf
docs(16-03): complete test suite and Windows PTY plan
loco1842 May 19, 2026
f002e3c
fix(16): add nil-guard for wailsApp in emitOutput and monitorExit
loco1842 May 19, 2026
a8da9da
test(16): update UAT — all 4 tests pass, gap closed
loco1842 May 19, 2026
ca9f0e8
docs(phase-17): create phase plans for xterm.js terminal and split pa…
loco1842 May 19, 2026
f5773fb
feat(17-01): install xterm.js v6 and addons (@xterm/xterm, addon-fit,…
loco1842 May 19, 2026
d1ac505
feat(17-01): create Terminal.tsx with xterm.js, FitAddon, WebglAddon,…
loco1842 May 19, 2026
a2d7d5b
feat(17-01): add terminal split pane CSS classes (terminal-pane, divi…
loco1842 May 19, 2026
bfbb484
docs(17-01): complete xterm.js Terminal component foundation plan
loco1842 May 19, 2026
dfa1506
feat(17-03): add ptyOutput/ptyExit event names and initEventNames pop…
loco1842 May 19, 2026
9be0bea
feat(17-03): subscribe to pty-output and pty-exit events in Terminal …
loco1842 May 19, 2026
bbf3c68
docs(17-03): complete wire PTY backend to xterm.js terminal plan
loco1842 May 19, 2026
c4d4753
feat(17-02): remove OutputPane state, import, shortcut, and output tr…
loco1842 May 19, 2026
1183abe
feat(17-02): add vertical split pane layout with resizable divider an…
loco1842 May 19, 2026
400e3e4
docs(17-02): complete split pane layout and OutputPane removal plan
loco1842 May 19, 2026
0a96aac
docs(17): create gap closure plan 17-04 for UAT Test 5 — route RunCom…
loco1842 May 19, 2026
e7c40ad
fix(17-04): route RunCommand output through pty-output event
loco1842 May 19, 2026
b200e8a
fix(17-04): remove dead streamLines/cmd-output code from App.tsx
loco1842 May 19, 2026
2cf7dd7
docs(18): create phase plan — PTY Write + keystroke forwarding + Ctrl+C
loco1842 May 20, 2026
9ebe27a
test(18-01): add failing test for PTY Write + terminalSvc
loco1842 May 21, 2026
20fd36c
feat(18-01): implement PTY Write + terminalSvc for RunCommand
loco1842 May 21, 2026
28a9c39
fix(18-01): simplify runCommandDirect to fire-and-forget per D-01
loco1842 May 21, 2026
031a146
docs(18-01): complete PTY Write execution + fire-and-forget Run path …
loco1842 May 21, 2026
145413c
feat(18-02): add term.onData keystroke buffering and forwardRef clear…
loco1842 May 21, 2026
1ece40f
feat(18-02): wire terminalRef and add Clear Terminal button in termin…
loco1842 May 21, 2026
351108d
docs(18-02): complete keystroke forwarding and terminal interactivity…
loco1842 May 21, 2026
e613431
docs(18): create gap closure plan 18-03 for UAT-diagnosed issues
loco1842 May 21, 2026
7fead8f
fix(18-03): task 1 - trim trailing newline from resolvedScript to pre…
loco1842 May 21, 2026
427d18e
fix(18-03): task 2 - full-write PTY loop, immediate keystroke flush, …
loco1842 May 21, 2026
d888e37
fix(terminal): add PTY resize forwarding, restore FitAddon, properly …
loco1842 May 21, 2026
62856b7
fix(run): remove cd ~ from cd sandwich, stay in working dir after exe…
loco1842 May 21, 2026
f1a97d5
feat(17-04): add cmd-output event subscription to Terminal.tsx
loco1842 May 21, 2026
618af2e
docs(19): capture phase context
loco1842 May 21, 2026
536372b
docs(phase-19): research terminal polish — theme sync, font transitio…
loco1842 May 21, 2026
614e79f
docs(19): finalize phase plan for terminal polish (theme sync + font …
loco1842 May 22, 2026
133c998
feat(19-01): sync terminal theme via CSS var mapping to xterm ITheme
loco1842 May 22, 2026
f1b68c4
feat(19-01): add 150ms opacity transition on terminal font change
loco1842 May 22, 2026
1564a3b
docs(19-01): complete terminal polish plan
loco1842 May 22, 2026
3676a8b
fix(19-01): set terminal-container background to var(--background)
loco1842 May 22, 2026
006ff41
fix(19-01): defer getComputedStyle read to requestAnimationFrame for …
loco1842 May 22, 2026
4773a81
fix: remove success toast on command execution (terminal shows output)
loco1842 May 22, 2026
717f32d
feat: add Ctrl+` shortcut to toggle terminal panel
loco1842 May 22, 2026
f093501
feat: auto-expand terminal when executing a command
loco1842 May 22, 2026
f6fb96c
docs(20): plan terminal copy buttons — cmd-executing event + Copy Cmd…
loco1842 May 22, 2026
87543d1
feat(20-01): add cmd-executing Wails event for command text tracking
loco1842 May 22, 2026
1b1e9f7
feat(20-01): add Copy Cmd and Copy Out buttons to terminal toolbar
loco1842 May 22, 2026
33c260a
refactor(20-01): move copy buttons inline onto terminal pane as overl…
loco1842 May 22, 2026
86c0256
refactor(20-01): replace copy overlay buttons with single Copy Output…
loco1842 May 22, 2026
41179aa
fix(20-01): gate copy buffer on command execution, match terminal scr…
loco1842 May 22, 2026
b49e43e
fix(20-01): force terminal scrollbar styles with !important
loco1842 May 22, 2026
617b394
feat: implement copy last output action
loco1842 May 27, 2026
2bdca13
fix: pty output race condition
loco1842 May 28, 2026
34e3842
feat: remove history pane
loco1842 May 28, 2026
c7073c5
chore: rm planning docs
loco1842 May 28, 2026
7ad120f
fix: add no-control-regex on type estype check
loco1842 May 28, 2026
d7fad7a
fix: resolve review
loco1842 May 28, 2026
88fe832
fix: resolve review
loco1842 May 28, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions .agents/skills/add-shadcn-component/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
name: add-shadcn-component
description: Add a new shadcn/ui component using the project's configured style and path aliases
disable-model-invocation: true
---

# Add shadcn/ui Component

Add a new shadcn/ui component to the project. Run from the `frontend/` directory:

```bash
cd frontend && pnpm dlx shadcn@latest add <component-name>
```

## Project Configuration
- **Style**: new-york
- **Base color**: neutral
- **Icon library**: lucide
- **CSS variables**: enabled
- **RSC**: disabled (not a Next.js project)
- **Components path**: `src/components/ui/`
- **Utils path**: `src/lib/utils.ts`

## Path Aliases
- `@/components` → `src/components`
- `@/components/ui` → `src/components/ui`
- `@/lib` → `src/lib`
- `@/hooks` → `src/hooks`

## After Adding
- Import using the alias: `import { Button } from '@/components/ui/button'`
- The component will use Tailwind CSS v4 with CSS variables for theming
- Customize colors via CSS variables in `src/style.css`, not by hardcoding values
105 changes: 105 additions & 0 deletions .agents/skills/todo-scanner/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
---
name: todo-scanner
description: "Scans the todos/ folder for *.pending.md files and creates implementation plans from their content using the writing-plans workflow. Use this skill whenever the user mentions checking todos, scanning pending tasks, reviewing todo files, processing pending items, or wants to plan work from markdown todo files. Also triggers on phrases like 'what's pending', 'any todos', 'plan my tasks', or 'work on todos'."
---

# Todo Scanner

Scan the project's `todos/` directory for markdown files with the `*.pending.md` naming convention, create implementation plans for their content, and mark them as resolved after execution is complete.

**Announce at start:** "Using todo-scanner to check for pending tasks in `todos/`."

## Workflow

### Step 1: Scan for pending files

Search `todos/` (relative to project root) for files matching `*.pending.md`. Use glob or ls:

```bash
ls todos/*.pending.md 2>/dev/null
```

**If none found:** Tell the user — "No pending todo files found in `todos/`. Create a file like `todos/my-task.pending.md` to get started." Then stop.

**If `*.resolved.md` files also exist:** Mention how many previous todos have been completed, for context.

### Step 2: Present findings and let user choose

List all `*.pending.md` files with a brief preview (first 3-5 lines) of each. Ask the user which file(s) they want to work on.

If only one pending file exists, show its preview and confirm: "This is the only pending task. Want to plan and work on it?"

### Step 3: Read and analyze the selected todo

Read the full content of the selected `*.pending.md` file. The content may be:

- **Freeform:** Plain text, bullet points, rough notes describing the task
- **Structured:** Sections with title, description, acceptance criteria, etc.

Either format works. Extract the core task requirements regardless of structure. If the content is ambiguous or underspecified, ask the user for clarification before proceeding to planning.

### Step 4: Create implementation plan

Use the **writing-plans** skill to create a detailed implementation plan based on the todo content.

- Treat the todo content as the spec/requirements input
- Ensure the output directory exists: `mkdir -p docs/superpowers/plans/`
- Save the plan to `docs/superpowers/plans/YYYY-MM-DD-<todo-name>.md` (derive `<todo-name>` from the pending filename, e.g., `fix-preset-preview.pending.md` → `fix-preset-preview`)
- Follow writing-plans conventions (bite-sized tasks, frequent commits). If the project has no test infrastructure yet, adapt TDD steps to manual verification or skip test steps — match the project's current state.
- In the plan header, note the source: `**Source:** todos/<filename>.pending.md`

**Important:** The plan's final task MUST be a "Mark todo resolved" step that renames the source file (see Step 6). This ensures the rename happens as part of normal plan execution flow.

### Step 5: Execute the plan

After the plan is written, offer execution options per the writing-plans handoff:

1. **Subagent-Driven** (recommended) — dispatch a fresh subagent per task, review between tasks
2. **Inline Execution** — execute tasks in the current session with checkpoints

### Step 6: Mark as resolved

The plan's final task should contain this step. It runs **only after all implementation tasks are complete:**

1. First, prepend the resolution header to the pending file:
```markdown
<!-- Resolved: YYYY-MM-DD | Plan: docs/superpowers/plans/YYYY-MM-DD-<name>.md -->
```
2. Then rename:
```bash
git mv todos/<name>.pending.md todos/<name>.resolved.md
```
(Use `git mv` so the rename is tracked. Fall back to plain `mv` if not in a git repo.)

**Do NOT rename before execution is complete.** The rename is the signal that the work described in the todo has been fully implemented.

**If a plan is abandoned:** Leave the file as `*.pending.md`. It can be picked up again in a future session.

**If `<name>.resolved.md` already exists (collision):** Do NOT use `git mv` — it will fail. Instead:
1. Append the full content of `todos/<name>.pending.md` (including its resolution header) to the existing `todos/<name>.resolved.md`
2. Detect git repo membership: run `git rev-parse --is-inside-work-tree`
3. If inside a git repo:
- Run `git rm todos/<name>.pending.md` to remove and stage the deletion
- Run `git add todos/<name>.resolved.md` to stage the updated resolved file
4. If not in a git repo:
- Run `rm todos/<name>.pending.md`

This avoids leaving the `*.pending.md` file in place and prevents `git mv` from erroring on an existing target.

## File Naming Convention

| State | Pattern | Example |
|-------|---------|---------|
| Pending | `todos/<name>.pending.md` | `todos/fix-preset-preview.pending.md` |
| Resolved | `todos/<name>.resolved.md` | `todos/fix-preset-preview.resolved.md` |

Names should be kebab-case and descriptive of the task.

## Checklist

- [ ] Scan `todos/` for `*.pending.md` files
- [ ] Present found files to user for selection
- [ ] Read and understand the selected todo content
- [ ] Create implementation plan using writing-plans skill
- [ ] Execute the plan (subagent-driven or inline)
- [ ] Rename `*.pending.md` → `*.resolved.md` after full completion
45 changes: 45 additions & 0 deletions .agents/skills/wails-feature/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
---
name: wails-feature
description: Guide for adding new Wails-bound features across Go backend and React frontend, following the project's established data flow pattern
---

# Wails Feature Workflow

When adding a new feature that spans backend and frontend, follow these steps in order:

## 1. Go Models (`models.go`)
- Add or update structs for any new data types
- Use `json:"camelCase"` tags matching the frontend conventions

## 2. Go Backend Logic (`app.go`)
- Add methods to the `App` struct
- Methods must be exported (capitalized) to be available as Wails bindings
- Use `a.store` for persistence and `a.executor` for command execution
- Follow existing patterns: return `(Type, error)` for creates/updates, `error` for deletes

## 3. Regenerate TypeScript Bindings
Run:
```bash
make generate
```
This regenerates `frontend/bindings/cmdex/` with updated TypeScript signatures for all exported service methods.

## 4. TypeScript Types (`frontend/src/types.ts`)
- Add or update interfaces to mirror the Go structs from step 1
- Keep field names in camelCase matching the JSON tags

## 5. React Components
- Import the generated binding: `import { MyMethod } from '../../bindings/cmdex/servicename'`
- If adding a modal, extend the `ModalState` discriminated union in `App.tsx`
- Add handler functions in `App.tsx` following existing patterns
- Create or update components in `frontend/src/components/`
- Use shadcn/ui components from `@/components/ui/` and Lucide icons
- Add any user-facing strings as i18n keys in `frontend/src/locales/en.json` and use `t('key')`

## Checklist
- [ ] Go struct added/updated in `models.go`
- [ ] App method added in `app.go`
- [ ] Bindings regenerated (`make generate`)
- [ ] TypeScript interface updated in `types.ts`
- [ ] React component created/updated
- [ ] i18n keys added to `locales/en.json`
22 changes: 22 additions & 0 deletions .opencode/prompts/executor-guideline.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Executor Agent Guidelines

**Purpose:** Execute commands or tool calls on behalf of another agent and return only the minimum useful result.

## Operating Rules

- Act as the default place for bash commands, tests, builds, formatters, linters, and validation requested by other agents.
- Execute only what the caller asked for.
- Never suggest next steps or fixes. The caller decides what to do.
- Do not try to fix any failure yourself. Just report it.
- Prefer command flags that reduce output such as `--quiet`, `--short`, `-q`, or `--format json` when they still answer the request.
- Run the smallest command or tool call that can answer the question before escalating to broader execution.
- Batch independent commands or tool calls when possible.

## Response Rules

- Never paste full logs or other raw output unless the caller explicitly asks for it.
- Keep the response compact and omit repetitive success lines, progress output, and ANSI noise.
- Always report whether execution succeeded.
- If execution failed, report the exit code, the key failure reason, and the exact files and lines involved when available.
- For tests or builds, report only the overall result, pass/fail counts, and the relevant errors with exact file and line references when available.
- If a raw excerpt is necessary, include only the shortest excerpt that supports the summary.
26 changes: 26 additions & 0 deletions .opencode/prompts/explore-guideline.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Exploration Guidelines

**Purpose:** Gather enough evidence to answer accurately while minimizing time, tokens, and unnecessary file access.

## Operating Rules

- Start with the smallest search that can answer the question.
- Prefer `glob`, `grep`, and targeted `read` calls over broad scans.
- Batch independent searches and reads when possible.
- Read only the specific files and sections needed to confirm the answer.
- Ignore noisy or generated directories such as `node_modules`, `dist`, `build`, `.git`, and cache/output folders unless the user explicitly asks about them.
- Stop exploring once the answer is supported by concrete evidence.

## Efficiency Rules

- Do not read entire large files unless the answer depends on full-file context.
- Do not scan unrelated directories just to be thorough.
- Reuse previously gathered evidence instead of repeating searches.
- Summarize findings clearly with exact file references.

## Safety Rules

- Respect least privilege at all times.
- Do not attempt to read secrets, credentials, or sensitive config outside the allowed workspace.
- Do not edit files, run destructive commands, or use network access unless explicitly required.
- If the requested scope is unclear, ask for the minimum clarification needed.
Loading
Loading