Skip to content

Linux support: work through the rough edges (linux-compat branch) #16

Description

@RyanSeanPhillips

Goal

Get CLD CTRL fully working on Linux. Windows has been the primary dev/test platform; the cross-platform scaffolding exists (core/platform.ts, core/setup-linux.ts) but has had little real-world testing. Work through the rough edges one by one on this machine.

Setup — read this first

  • Do NOT work in ~/Dropbox/CLDCTRL. This computer shares the Dropbox account with the Windows dev machine, so that path is the same working tree and .git dir being edited over there. Two machines + Dropbox sync on one git repo corrupts the index and mixes build artifacts. Instead:
    git clone https://github.com/RyanSeanPhillips/cldctrl.git ~/code/cldctrl
    cd ~/code/cldctrl && git checkout linux-compat
  • Branch workflow: commit Linux fixes to linux-compat (currently identical to master at a93dee6), push it, merge to master once the smoke sequence below passes end-to-end. The Windows machine keeps committing to master; rebase linux-compat on master as needed.
  • Build prerequisites: Node 18+, plus a toolchain for node-pty (native module): build-essential/g++, make, python3. Then:
    cd packages/cli && npm install && npx tsup && npm link

Smoke sequence (in order of increasing platform risk)

  1. cc --version — startup path, config dir resolution (~/.config/cldctrl/)
  2. cc list --json — project discovery, git status spawning
  3. cc --demo --snapshot then cc --demo — TUI + diff renderer on a Linux terminal
  4. cc serve → open http://localhost:2533 — dashboard, daemon cache, usage probing
  5. Resume a real conversation into a cockpit tile — node-pty spawn, claude --resume, WS terminal
  6. Pop the tile out (↗) — chromeless window launch (needs google-chrome or chromium on PATH)
  7. Close everything, reopen within 8 min → windows auto-relaunch; wait 8+ min, reopen → restore banner + spatial chooser (new in a93dee6)
  8. cc setup — Linux hotkey via systemd user timer (least tested path of all)

Known/likely rough edges

  • node-pty build failures → everything terminal-shaped in the dashboard dies. Check first.
  • Path handling: Windows is case-insensitive with \ separators; grep for hardcoded \\ handling and drive-letter assumptions. normalizePathForCompare() (core/platform.ts) exists for the Windows case — verify Linux behavior. Claude project-slug generation from cwds is worth checking early.
  • App-mode / pop-out window launch (core/app-launch.ts): Chrome discovery is Windows-pathed; needs a Linux browser probe. The restore feature degrades to grid tiles on launch failure, so nothing is lost — but fix the probe.
  • Instance guard: the per-virtual-desktop logic is Windows COM (desktop-probe.ps1); Linux should fall back to global single-instance — verify it doesn't spawn PowerShell.
  • Vendor CLIs: Antigravity discovery uses %LOCALAPPDATA%\agy\bin; Codex resume paths untested on Linux. These should no-op gracefully when absent — confirm they don't throw.
  • Notifications: node-notifier on Linux needs notify-send (libnotify).

Reporting

File one issue per confirmed rough edge (label linux), reference this issue, and note fixes in commits on linux-compat. Update this issue''s checklist as smoke steps pass.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions