Conversation

andyleejordan

The debug build creates a symlink to PSES, rebuilds PSES, does not
minify the extension, and generates a TypeScript sourcemap. The release
build deletes the symlink if it exists and copies PSES, only builds PSES
if not already copied, minifies the extension, and does not generate a
TypeScript sourcemap. This removes the manual LinkEditorServices step
and ensures that the developer debugging experience works well.

@andyleejordanandyleejordan added the IgnoreExclude from the changelog.label Jan 20, 2022
@andyleejordanandyleejordan changed the title Setup Release task in Invoke-Build Introduce Debug and Release configurations Jan 20, 2022
@andyleejordanandyleejordan force-pushed the andschwa/release-task branch 2 times, most recently from c301a87 to 019112a Compare January 20, 2022 19:22
@andyleejordanandyleejordan marked this pull request as draft January 20, 2022 19:38
@andyleejordanandyleejordan force-pushed the andschwa/release-task branch 6 times, most recently from 7e2d219 to 98210d2 Compare January 20, 2022 20:52
@andyleejordanandyleejordan marked this pull request as ready for review January 20, 2022 20:57
@andyleejordanandyleejordan enabled auto-merge (squash) January 20, 2022 21:50
@andyleejordanandyleejordan changed the title Introduce Debug and Release configurations Introduce Debug and Release configurations Jan 20, 2022
@andyleejordan

@JustinGrote Want to help me merge this 😂

The debug build creates a symlink to PSES, rebuilds PSES, does not
minify the extension, and generates a TypeScript sourcemap. The release
build deletes the symlink if it exists and copies PSES, only builds PSES
if not already copied, minifies the extension, and does not generate a
TypeScript sourcemap. This removes the manual `LinkEditorServices` step
and ensures that the developer debugging experience works well.
@andyleejordanandyleejordan force-pushed the andschwa/release-task branch 2 times, most recently from 958967e to d396435 Compare January 21, 2022 01:41
@JustinGrote

@andschwa shouldn't the code workspace include a debug build task?
image

@JustinGrote

Also while not necessary to cover in this PR, I really would like to figure out a way to build a "watch" that, on C# change, would rebuild editor services and reload the extension host. dotnet watch run can cover the first part, I don't know if we can figure out a hook to reload the extension host debug process.

@andyleejordan

@andschwa shouldn't the code workspace include a debug build task?
image

Doesn't need a debug "task" since it has a debug launch configuration (both of them, actually):

Screen Shot 2022-01-21 at 1 55 51 PM

"Launch Extension" launches the extension under the VS Code debugger (and this PR explicitly ensure that actually works well by not minifying the code when developing), and "Attach to Editor Services" then will ask for the pwsh process to attach to (running under that launched Code instance with the extension).

If you're asking if the build task needs to be in -Configuration Debug, that's just the default build. -Configuration Release is only needed when releasing, and the automated pipelines do exactly that.

@andyleejordan

Also while not necessary to cover in this PR, I really would like to figure out a way to build a "watch" that, on C# change, would rebuild editor services and reload the extension host. dotnet watch run can cover the first part, I don't know if we can figure out a hook to reload the extension host debug process.

I'll look into it!

@JustinGrote

LGTM then, I didn't notice debug was the default, that explains what I missed.

@andyleejordanandyleejordan merged commit 1be200b into master Jan 21, 2022
@andyleejordanandyleejordan deleted the andschwa/release-task branch January 21, 2022 23:13
fflaten added a commit to fflaten/vscode-powershell that referenced this pull request Aug 3, 2023
Task was removed in PowerShell#3775, now automatic for Debug-builds.
andyleejordan pushed a commit that referenced this pull request Aug 3, 2023
Task was removed in #3775, now automatic for Debug-builds.
Sign up for free to join this conversation on . Already have an account? Sign in to comment
IgnoreExclude from the changelog.
None yet

Successfully merging this pull request may close these issues.