Skip to content

Add a default for saveBeforeStart setting #3338

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

Closed
TylerLeonhardt opened this issue May 6, 2021 · 7 comments · Fixed by #3357
Closed

Add a default for saveBeforeStart setting #3338

TylerLeonhardt opened this issue May 6, 2021 · 7 comments · Fixed by #3357
Assignees
Labels
Area-Configuration Issue-Bug A bug to squash. Up for Grabs Will shepherd PRs.

Comments

@TylerLeonhardt
Copy link
Member

All you have to do is add:

"configurationDefaults": {
      "[powershell]": {
        "debug.saveBeforeStart": "nonUntitledEditorsInActiveGroup"
      }
    },

under contributes in the package.json.

here's an example:
https://github.com/microsoft/vscode/blob/bce4d71f648a963cad905ee0ecc7b353ddd3f199/extensions/markdown-language-features/package.json#L311

Then Untitled file debugging will no longer prompt to save :)

Note: VS Code made this setting "language-aware" literally today. So this will work starting with tomorrow's insider build. There's no downside of this being set for those folks on older versions of VS Code so this change can really go in whenever.

cc @isidorn

@ghost ghost added the Needs: Triage Maintainer attention needed! label May 6, 2021
@SydneyhSmith SydneyhSmith added Area-Configuration Issue-Bug A bug to squash. Up for Grabs Will shepherd PRs. and removed Needs: Triage Maintainer attention needed! labels May 12, 2021
@andyleejordan
Copy link
Member

Is this a duplicate of #3200?

@andyleejordan andyleejordan added the Needs: Maintainer Attention Maintainer attention needed! label May 18, 2021
@SydneyhSmith
Copy link
Collaborator

Yep, looks like this would resolve #3200

@SydneyhSmith SydneyhSmith removed the Needs: Maintainer Attention Maintainer attention needed! label May 18, 2021
@TylerLeonhardt
Copy link
Member Author

This is a better solution than the other :)

@ghost ghost added the Needs: Maintainer Attention Maintainer attention needed! label May 18, 2021
@andyleejordan andyleejordan added this to the Committed-vNext milestone May 20, 2021
@andyleejordan andyleejordan removed the Needs: Maintainer Attention Maintainer attention needed! label May 20, 2021
@andyleejordan andyleejordan self-assigned this May 20, 2021
@andyleejordan
Copy link
Member

@TylerLeonhardt Is this new enough?

29c61570a5b9a669f777bb28b5acd5c37d99edbe
Date: 2021-05-20T05:41:52.156Z (12 hrs ago)

It doesn't seem to be working...maybe I have something else going on.

@andyleejordan
Copy link
Member

andyleejordan commented May 20, 2021

I've double checked what I added to package.json against microsoft/vscode#117100 ...hm, I'll open a draft PR and maybe I erred?

@TylerLeonhardt
Copy link
Member Author

Yeah it looks like that setting isn't working as expected. @isidorn, any thoughts?

@ghost ghost added the Needs: Maintainer Attention Maintainer attention needed! label May 20, 2021
@isidorn
Copy link
Contributor

isidorn commented May 21, 2021

Thanks for doing this PR.
There was an issue on the VS Code side that I tackled via microsoft/vscode@779f987

So now it should work. I tried it out.
You can verify with vscode insiders from Monday. Thanks a lot 👏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Configuration Issue-Bug A bug to squash. Up for Grabs Will shepherd PRs.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants