Skip to content

Add Windows PowerShell hook commands#2

Open
AndreKalberer wants to merge 2 commits into
warpdotdev:mainfrom
AndreKalberer:andrekalberer/codex-hooks-powershell-windows
Open

Add Windows PowerShell hook commands#2
AndreKalberer wants to merge 2 commits into
warpdotdev:mainfrom
AndreKalberer:andrekalberer/codex-hooks-powershell-windows

Conversation

@AndreKalberer

@AndreKalberer AndreKalberer commented Jul 8, 2026

Copy link
Copy Markdown

Summary

  • Add commandWindows overrides so Codex uses PowerShell hook entrypoints on Windows instead of invoking .sh files directly.
  • Add native PowerShell implementations for the Warp notification hooks and Oz orchestration bridge hooks.
  • Document the Windows hook path and extend hook manifest tests to cover the Windows overrides.

Linked Issue

Closes warpdotdev/warp#13391

Manual Windows Evidence

Before - upstream main uses .sh hook commands on Windows

Tested against upstream main at f11334d. Installing warp@codex-warp and running the Codex hook smoke test causes Windows to show the app-selection dialog for opening a .sh file.

before-sh-dialog-compressed.mp4

After - this PR uses PowerShell hook commands on Windows

Tested against this PR at 5c01e7c. Installing warp@codex-warp from the patched branch and running the same Codex hook smoke test completes without the .sh app-selection dialog. The visible hook log shows SessionStart, UserPromptSubmit, and Stop completing.

after-powershell-hooks-compressed.mp4

Testing

  • Get-ChildItem -Recurse -Filter *.ps1 | ForEach-Object { ... [System.Management.Automation.Language.Parser]::ParseFile(...) ... }
  • Get-Content -Raw plugins/warp/hooks/hooks.json | ConvertFrom-Json; Get-Content -Raw plugins/orchestration/hooks/hooks.json | ConvertFrom-Json
  • C:\Program Files\Git\bin\bash.exe tests/test-hooks.sh
  • Windows PowerShell smoke: Warp payload builder + orchestration mailbox drain/stop block
  • Windows PowerShell smoke: orchestration listener launch through on-session-start.ps1 + cleanup through on-session-end.ps1
  • Manual Windows before/after capture using warp@codex-warp from upstream main (f11334d) and this PR branch (5c01e7c)

@AndreKalberer AndreKalberer marked this pull request as ready for review July 8, 2026 21:18
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.

Codex hooks on windows should default to powershell

1 participant