Repository navigation
Description
Today kit runs on macOS, Linux, and Windows via WSL2 / Git Bash / Docker (documented in docs/PLATFORM_SUPPORT.md). Native Windows (PowerShell/cmd, no POSIX shell) is not supported yet. This issue tracks the concrete blockers found in a compatibility audit so the work can be picked up incrementally.
The runtime is already cross-platform-careful: execFile with arg arrays (no shell), os.homedir() / %APPDATA% resolution, platform-routed start/open/xdg-open, and a win32 BitLocker branch in the disk-encryption check. The blockers are at the operational edges.
Hard blockers
- Git hooks are POSIX shell scripts.
src/hooks.tswrites#!/bin/shhooks usingdate,stat -c/-f,rm. Rewrite as Node-based hooks (invokenode/kitdirectly) or emit.ps1/.cmdwith conditional install. -
whichfor tool resolution.src/utils/resolveTool.ts:23shells out towhich. Add a Windows path (where, or PATH/PATHEXT scan).mise whichfast path already works. -
tarfor archive extraction.src/bumblebee.tsandsrc/triage-sandbox.tscalltar. Use a cross-platform extractor (Node tar lib) or gate on availability. - Secret-file permissions rely on POSIX mode bits.
0600/0700viachmod/writeFile({mode})for~/.kit/memory.db,elevation.key, materialized.env.localare no-ops on NTFS. Apply Windows ACLs (icacls) or document the gap + warn at runtime on native Windows. - Build script is POSIX (
package.json:rm -rf dist && tsc && chmod +x dist/cli.js). Userimraf/a JS build runner and drop thechmodon Windows.
Soft / follow-up
- Bumblebee binaries are released for linux/darwin only (
resolveTargetreturns null for win32). Either ship Windows builds or keep the scanner gated off on native Windows. - Windows CI. Add a
windows-latestjob so native support doesn't regress once implemented. -
manage-bderequires elevation — non-admin runs silently skip the disk-encryption check (acceptable, but note it).
Acceptance
kit init / check / setup / context check run end-to-end in PowerShell on a clean Windows box, with hooks installed and secret files protected by ACLs, verified by a windows-latest CI job.
Reference: docs/PLATFORM_SUPPORT.md.
🤖 Generated with Claude Code
Activity
fix(win): resolveToolBin uses 'where' on native Windows, 'which' else…
sandstream commentedon Jun 24, 2026
Checked off
whichfor tool resolution:resolveToolBinnow useswhereon win32,whichelsewhere (1.28.1, #108). Remaining hard blockers (POSIX git hooks,tarextraction, secret-file ACLs, build-scriptrm/chmod) + awindows-latestCI job need a Windows runner to implement + verify — leaving open for a Windows-equipped session.build(win): cross-platform build script + windows-latest probe CI (#43)…
sandstream commentedon Jun 24, 2026
First real windows-latest probe run (CI workflow now valid + on main):
npm ciworksfs.rmSync, chmod→win32-noop node script; 1.28.2) is verified. Build blocker cleared.tar, secret-file ACLs, path handling surfaced via the suite). The specific failures aren't capturable from gh's truncated CI logs — needs Windows-side diagnosis (a real box or richer log capture) to fix verify-driven without guessing.Shipped so far for #43:
which→wheretool resolution (1.28.1) + cross-platform build (1.28.2, Windows-verified) + thewindows-latestprobe workflow itself. The probe is the verify-loop foundation; the remaining runtime blockers need readable Windows test output to fix responsibly.fix(win): no-dep cross-platform test runner (#43)
fix(win): os.devNull instead of literal /dev/null in secrets-sync (#43)
chore(release): 1.29.1 — Windows tests run (test-runner + /dev/null +…
fix(win): tests run on native Windows + diagnosable probe → 1.29.1 (#43…
sandstream commentedon Jun 24, 2026
Windows status after 1.29.1: builds ✓, 1526/1542 unit tests pass (99%)
Verify-loop built (windows-latest probe + downloadable test-log artifact). Fixed:
which→where(1.28.1), cross-platform build (1.28.2), no-dep test runner +os.devNull(1.29.1). The suite now runs on Windows.Remaining 15 failures — categorized work-list
A. POSIX-path /
startsWith("/")assumptions (mostly TEST fixes, tractable):resolveToolBintest — asserts paths start with/(Windows:D:\…)mise-path helpers—miseShimsDir/activationLineassume POSIX~/.local/share/...memoryDirInsideRepo— path-prefix comparison with/loadPluginAdapters— likelyfile://URL / path separatorscloneRepository—.kit.tomlpresence / readable-dir path checksB. chmod /
0o600permission semantics (needs a DECISION):installHooks("makes hook files executable"),memory hook installer,mcp-orchestrator token store("token file is chmod 0o600"),ensureBumblebeesidecaricacls) for the secret files (memory.db, elevation.key, tokens) or accept-and-warn the gap on native Windows. This is the substantive call — recommend documenting the gap + a runtime warning first, ACLs as a hardening follow-up.Category A is mechanical (platform-aware path handling/assertions). Category B is the real security-semantics decision. Both now have a real
windows-latestrunner to verify against.chore(release): 1.30.0 — Windows ACLs (icacls) for secret files (#43-B)
feat(win): icacls ACLs for secret files (#43-B) → 1.30.0 (#118)
sandstream commentedon Jun 24, 2026
Windows ACLs shipped (1.30.0) — perms half of #43 done
secure-perms(icacls on win32) now protects memory.db, mcp-tokens, elevation.key, totp-secret. POSIX unchanged.Precise map of the remaining 15 (exact locations, categorized)
Real path/handling fixes:
clone.test.js:70(detect.kit.toml) +:156(readable dir, ENOENT README) — clone path handling on WindowsmemoryDirInsideRepo— path-prefix compare with/mise-path helpers(miseShimsDir/activationLine) — POSIX~/.local/share/...assumptionloadPluginAdapters—file://URL / separatorsresolveToolBintest — asserts paths start with/Accept-the-gap on Windows (feature genuinely unavailable → skip-on-win32):
bumblebee.test.js:196/207/218— returnsunsupported(no win32 bumblebee binary;resolveTargetis null for win32). Expected — skip these on win32 (or ship a win build).check-disk-encryption.test.js:28— BitLocker state on the runner; make platform-aware.Perm-test mode-bit assertions (now that ACLs are the win32 mechanism):
hooks.test.js:81(executable bit — no-op on NTFS),mcp-orchestrator token store("chmod 0o600"),memory hook installer— assert via the newsecure-permssemantics on win32 instead of POSIX mode bits.Each is now pin-pointed + the
windows-latestprobe (+ test-log artifact) verifies fixes. This is a focused port with a couple of accept-the-gap judgment calls (bumblebee/BitLocker) — best done deliberately.sandstream commentedon Jun 27, 2026
Status audit — most hard blockers are already resolved
Re-checked each blocker against current
main:rm -rf/chmod)buildusesnode scripts/clean-dist.mjs+scripts/chmod-cli.mjs(win32-guardedchmodSync)whichfor tool resolutionresolveTool.ts:process.platform === "win32" ? "where" : "which"src/utils/secure-perms.tshas anicacls /inheritance:r /grant:rbranch for file (:F) and dir ((OI)(CI)F) on win32resolveTargetreturns null on win32 (scanner gated off, not a crash).github/workflows/windows.yml(windows-latest) runskit --version+kit check --category securityGenuine remainders (need a real Windows runner to verify — won't blind-ship)
src/hooks.tswrites#!/bin/shusingdate,stat -c/-f,rm). The real hard blocker. Needs a Node-based hook rewrite (or.ps1/.cmdemission) and a Windows job that actually installs + fires the hooks to verify — not safely doable from a Linux-only environment.tarflags intriage-sandbox.tsuse GNU-style--no-same-owner --no-same-permissions; Windows' bundled bsdtar (tar.exe) may reject them. Needs win32 verification (bumblebee's tar is already win32-gated off).Per kit's verify-before-claim discipline, I'm not rewriting the hooks blind — shipping unverifiable Windows hooks is worse than an honest open item. Narrowing this issue to the two remainders above; the acceptance criterion still stands (kit init/check/setup end-to-end in PowerShell, hooks installed, verified by the windows-latest job — which should be extended to exercise
kit hooksonce the rewrite lands).Generated by Claude Code
sandstream commentedon Jul 1, 2026
Native Windows shipped in 2.1 — PLATFORM_SUPPORT.md: build+test green on windows-latest. Residual graceful-degrade gaps tracked separately if needed.