Skip to content

v0.3.0 — hand-rolled ConPTY, leaner deps

Latest

Choose a tag to compare

@shero4 shero4 released this 18 Apr 10:04

What's new

Internal refactor of the PTY layer. No user-facing behaviour change from v0.2.1 on either platform; Windows keeps the same functional behaviour with one minor cosmetic artifact (see below).

  • Dropped deps: github.com/aymanbagabas/go-pty, github.com/u-root/u-root, golang.org/x/crypto. Binaries are a little smaller, dep graph is trimmer.
  • Direct PTY backends:
    • Unix: github.com/creack/pty (was a transitive dep, now direct).
    • Windows: a minimal ConPTY wrapper in pty_windows.go, based on UserExistsError/conpty (MIT), built on golang.org/x/sys/windows. Supports .cmd / .bat shims via cmd.exe /c wrapping, useful if claude is npm-installed.
  • Platform-neutral PTY type in pty.go over a per-OS backend interface. Future Windows experiments (ConPTY flags, input-mode tweaks) have a clean home.

Windows status

ConPTY's PSEUDOCONSOLE_PASSTHROUGH_MODE was investigated as a fix for the minor "dismissed-modal ghost line" artifact. The system-wide CreatePseudoConsole accepts the flag but its implementation produces worse rendering than the translating-mode default, so it's not used. The nested-ConPTY VT re-translation remains a Microsoft-side limitation; fixing it cleanly would require access to Microsoft's private OpenConsole.exe. Acceptable for now.

Downloads

OS Arch Binary
Linux amd64 clod-linux-amd64
Linux arm64 clod-linux-arm64
macOS amd64 clod-darwin-amd64
macOS arm64 clod-darwin-arm64
Windows amd64 clod-windows-amd64.exe
Windows arm64 clod-windows-arm64.exe

Verify with sha256sum -c SHA256SUMS (Unix) or Get-FileHash (Windows).