sandhje / vscode-phpmd

VSCode PHP Mess Detector extension
MIT License
15 stars 4 forks source link

phpmd.rules setting #58

Open ghost opened 4 years ago

ghost commented 4 years ago

Greetings, if I have the path to a ruleset file defined as follows "phpmd.command": "${workspaceFolder}/vendor/bin/phpmd"

I get the following error: image

But if I have it like: "phpmd.command": "./vendor/bin/phpmd"

I get no error output, maybe the explanation of the plugin should be updated so that their is an explanation that you can use the ./vendor/bin/phpmd syntax if you have it as a dependency in your project. Or Autodiscover from composer the composer.json if it is a project dependency and if it is use that one.

sandhje commented 3 years ago

"${workspaceFolder}" should have been replaced in your command. I'll try to reproduce and submit a fix if I can find the problem

slmtbdwry commented 2 years ago

Hi, I got the error also on multi-root workspace, which with ${workspaceFolder:dirname} not parsed correctly, while without dirname it's OK although it automatically takes the first dirname (supposedly)