You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Execute git operations using cmd /c on windows fails #11288
Root Cause: The error message 'export is not recognized as an internal or external command' indicates that bash shell syntax is being executed in Windows cmd.exe, which doesn't support the 'export' command. This is a shell mismatch issue where bash commands are being sent to cmd.exe instead of being properly executed in a bash shell.
Feel free to ignore if none of these address your specific case, but checking #631 (the Windows support umbrella) and #10871 (bash auto-detection) would be most relevant.
Activity
github-actions commentedon Jan 30, 2026
This issue might be a duplicate of or related to existing issues. Please check:
Root Cause: The error message 'export is not recognized as an internal or external command' indicates that bash shell syntax is being executed in Windows cmd.exe, which doesn't support the 'export' command. This is a shell mismatch issue where bash commands are being sent to cmd.exe instead of being properly executed in a bash shell.
Feel free to ignore if none of these address your specific case, but checking #631 (the Windows support umbrella) and #10871 (bash auto-detection) would be most relevant.
DaveW001 commentedon Jan 30, 2026
Reproduced this behavior with a slightly different signature affecting PowerShell.
Additional Symptoms:
CommandNotFoundExceptionon the=token (caused byVAR=valsyntax).nulin the working directory (caused by> /dev/nullredirection failing in Windows).This confirms the issue affects both CMD (reporting
exporterror) and PowerShell (reporting=error).Likely caused by #10871 (failed Bash detection) causing fallback to native Windows shells while passing Bash-specific syntax.
xq114 commentedon Feb 22, 2026
I workaround it by disabling hook
non-interactive-envin oh-my-opencode.json:franshjy commentedon Mar 3, 2026
Can vouch for this, although not sure perhaps this might me an omo issue?
BeanYa commentedon Mar 24, 2026
I ran commands and opencode just got a death loop on running 'export' while I was working on Windows Powershell.
This works for me:
github-actions commentedon Jul 3, 2026
To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.