Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simplify generated launch.json #318

Closed
3 tasks
isidorn opened this issue Nov 13, 2018 · 5 comments
Closed
3 tasks

Simplify generated launch.json #318

isidorn opened this issue Nov 13, 2018 · 5 comments

Comments

@isidorn
Copy link

isidorn commented Nov 13, 2018

Hey,

VSCode dev here. This milestone I am looking into simplifing generated launch.json for various extensions microsoft/vscode#62851

The launch.json that PHP generates is attached at the end. I think it is cool and not too complex but we can improve this a bit

If you agree with the suggestions I am making here I am also here to help with any potential questions you might have. The changes should not require a lot of work but will simplify the flow a lot imho. It should be much less complex and not too much like a wizard experience

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Listen for XDebug",
            "type": "php",
            "request": "launch",
            "port": 9000
        },
        {
            "name": "Launch currently open script",
            "type": "php",
            "request": "launch",
            "program": "${file}",
            "cwd": "${fileDirname}",
            "port": 9000
        }
    ]
}

@isidorn
Copy link
Author

isidorn commented Nov 20, 2018

@felixfbecker Are there any plans to address this?
Do you agree with my suggesstions here?
If you do not have cycles to address this but would like to see it done, I can try to get some users to provide a PR which tackles this.

Thanks a lot

@felixfbecker
Copy link
Contributor

The suggestions make sense to me, but unfortunately I don't have capacity to implement them. Happy to review a PR though.

@isidorn
Copy link
Author

isidorn commented Nov 20, 2018

Thanks for your reponse. I will add a Help Wanted in the issue in VSCode and we will see if we get some volunterees

@AnrDaemon
Copy link

Re: port: there's no other way to differentiate debugging sessions.
Yes, you would not change it often, but you WILL have change it, when need to debug more than one script at a time, or when connecting foreign debugger configured for a different port.

@zobo
Copy link
Contributor

zobo commented Apr 11, 2022

This is a terribly old issue. But let's see:

  • I would not remote port as it's so important and using the wrong one causes the worst problems (debugging does not start). By leaving it there, the user is reminded of it. We have a resolveDebugConifguraiton call now and I plan to extend it with php executable and Xdebug detection. But that can only work when starting the debug program. In listen scenario, we are still unable to do this.
  • quickPick sound interesting, I'll make a task and see how it works out.
  • configurationSnippets were implemented

@zobo zobo closed this as completed Apr 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants