Skip to content

Cross-platform port (Linux + macOS) — WIP#4

Draft
saiko-psych wants to merge 4 commits into
mainfrom
feat/cross-platform-port
Draft

Cross-platform port (Linux + macOS) — WIP#4
saiko-psych wants to merge 4 commits into
mainfrom
feat/cross-platform-port

Conversation

@saiko-psych

Copy link
Copy Markdown
Owner

Work-in-progress port to Linux + macOS. Not for merge yet — the GUI
integration still needs validation on real Linux/macOS machines.

Done (CI-verifiable)

  • Cross-platform autostart — Windows Run key / Linux XDG .desktop /
    macOS LaunchAgent (autostart.py), with tests.
  • macOS backend _darwin.py (mirrors _linux; no xvfb, os.kill liveness,
    Homebrew/macOS paths) + factory dispatch darwin -> _darwin, with tests.

TODO (need a real Linux/Mac to validate the GUI)

  • preflight per-OS (Linux/macOS openconnect detection, no Wintun).
  • cross-platform CLI (up/down/status via the factory) + elevation
    abstraction (Windows Scheduled Task / Linux pkexec / macOS osascript).
  • decouple gui.py from the Windows-only modules so it runs on Linux/macOS.

🤖 Generated with Claude Code

coding-saiko and others added 4 commits June 7, 2026 11:47
…ent)

First brick of the Linux/macOS port. autostart now dispatches by platform:
Windows Run key (unchanged), Linux XDG autostart desktop entry, macOS
LaunchAgent plist. Adds launch_argv() (list form) for the .desktop Exec and
plist ProgramArguments; launch_command() (Windows registry string) builds on
it. Tested on the Linux CI (XDG round-trip + plist/desktop content).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Mirrors the working _linux backend for macOS: two-stage bring-up
(openconnect-sso auth -> openconnect tunnel), credentials from the Keychain
via keyring. macOS adaptations: no xvfb (the GUI session has a display),
process liveness via os.kill(pid, 0) (no /proc), Homebrew openconnect path,
macOS kill paths. Factory now routes darwin -> _darwin (was a silent no-op).
16 mocked tests (mirrors test_linux); full suite 180 green.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
… hardware

Runs the suite + an import smoke on macos-latest, gated to pull_request events
so it doesn't burn 10x macOS minutes on every main push. Headless: validates
the macOS backend + package import; the live GUI/tunnel still need a real Mac.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- check_all omits the Wintun + vpnc-script-win.js checks on non-Windows
  (Linux/macOS use the kernel tun/utun + openconnect's built-in vpnc-script).
- check_openconnect gives a package-manager hint (fix.openconnect_unix, no
  download button) on Linux/macOS instead of the Windows installer action.
- detect_openconnect now finds the Unix binary (PATH + /usr/sbin, /usr/bin,
  Homebrew paths) so the prereq panel is correct on EndeavourOS/macOS.
- New test_factory: guards the headless cross-platform API Termino integrates
  with (importable, per-OS dispatch, no-op-when-disabled on every platform) so
  the GUI port can't break it.

186 tests green.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants