Where does the bug appear (feature/product)?
Cursor IDE
Describe the Bug
Hello,
PowerShell execution inside Cursor has recently become almost unusable.
This is no longer an occasional issue — errors happen constantly, even with very simple commands, and even when using advanced models such as Opus 4.5.
Cursor frequently generates or executes invalid PowerShell syntax, resulting in endless parser errors. These issues occur repeatedly and are not isolated cases.
Examples (not exhaustive):
At C:\Users...\AppData\Local\Temp\ps-script-0a29c777-4962-4f1d-87ed-fb358ee79fc9.ps1:56 char:144
- … ata\Local\Temp\ps-state-out-58f3f17b-acf9-4845-895b-4354e1269c58.txt"
-
~
The string is missing the terminator: ".
+ CategoryInfo : ParserError: (
, ParentContainsErrorRecordException
+ FullyQualifiedErrorId : TerminatorExpectedAtEndOfString
And very frequently:
The token ‘&&’ is not a valid statement separator in this version.
Observed behavior:
CMD-style operators like && are generated and executed in PowerShell.
Long paths (especially with non-ASCII characters) often break string termination.
Errors occur even in trivial scripts.
Temporary scripts (ps-script-*.ps1) generated by Cursor frequently contain invalid syntax.
Re-asking the model to fix the script usually reproduces the same issues.
At this point, PowerShell automation in Cursor is unreliable and unstable, especially compared to Bash or Python workflows.
A clear, reliable solution or official workaround is needed (e.g. enforced PowerShell-safe syntax, proper command separation, or a stable execution mode).
Without this, PowerShell-based workflows are effectively blocked.
Steps to Reproduce
powershell
Operating System
Windows 10/11
Current Cursor Version (Menu → About Cursor → Copy)
Version: 2.3.41 (user setup)
VSCode Version: 1.105.1
Commit: 2ca326e0d1ce10956aea33d54c0e2d8c13c58a30
Date: 2026-01-16T19:14:00.150Z
Electron: 37.7.0
Chromium: 138.0.7204.251
Node.js: 22.20.0
V8: 13.8.258.32-electron.0
OS: Windows_NT x64 10.0.19045
Does this stop you from using Cursor
No - Cursor works, but with this issue