Hello,

That is quite useful. I'm adding it to the list.

Thank you

    runminlook May I ask how is it used?

    Do you start your own php with -dxdebug.port=${port} arguments in vscode's launch.json?



      If I use PHP Debug in VSCode, I config a launch like the above image. It can start multiple center service intances.

      But I think another design is let the extension do it for user.

      runminlook I see, thank you.

      We are setting all those "runtimeArgs" automatically, but your configuration will work as well.

      "port": 0 is a good idea.

        5 days later

        We have implemented the "port": 0 feature. it will be available in the next update.

        Note, that it is not necessary to specify "runtimeArgs" with our extension. The launch profile would look like the following:

        {
            "name": "Launch Built-in server",
            "type": "php",
            "request": "launch",
            "runtimeArgs": [
                "-S",
                "localhost:8000",
                "-t",
                "./php/center"
            ],
            "port": 0,
            "serverReadyAction": {
                "action": "openExternally"
            }
        }

        (https://docs.devsense.com/en/vscode/debug/launch-json#built-in-php-server)

          Write a Reply...