paul-gauthier / aider

aider is AI pair programming in your terminal
https://aider.chat/
Apache License 2.0
12.56k stars 1.2k forks source link

Test Command does not support arguments on Windows. #741

Open nevercast opened 3 days ago

nevercast commented 3 days ago

Using PowerShell inside VSCode on Windows 11 with Python 3.10 and Aider 0.40.5.

aider --test-cmd "npm run check" --test gives

Aider v0.40.5
...
'"npm run check"' is not recognized as an internal or external command, operable program or batch file 

Presumably you're calling out to shell (cmd, Windows) to execute the command, seems the quoting isn't working as I would expect.

I get the same output if I single or double quote, so it's not PowerShell that I'm calling aider from at fault, but instead how the execution is being constructed I suspect

Expected output would be that aider properly handles invoking a command with arguments on Windows.

I would expect this to work for lint-cmd too, I have not tested it.

I also have not tested using the config file, only command line invocation.

I have not checked the source code, but may do so in the coming days.