-
Notifications
You must be signed in to change notification settings - Fork 8.1k
Make sure MSI build works when not preview #7752
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -2521,14 +2521,14 @@ function New-MSIPackage | |
| [Environment]::SetEnvironmentVariable("ProductVersionWithName", $productVersionWithName, "Process") | ||
| if (!$isPreview) | ||
| { | ||
| [Environment]::SetEnvironmentVariable("PwshPath", '', "Process") | ||
| [Environment]::SetEnvironmentVariable("PwshPath", "[$productDirectoryName]", "Process") | ||
| [Environment]::SetEnvironmentVariable("UpgradeCodeX64", '31ab5147-9a97-4452-8443-d9709f0516e1', "Process") | ||
| [Environment]::SetEnvironmentVariable("UpgradeCodeX86", '1d00683b-0f84-4db8-a64f-2f98ad42fe06', "Process") | ||
| [Environment]::SetEnvironmentVariable("IconPath", 'assets\Powershell_black.ico', "Process") | ||
| } | ||
| else | ||
| { | ||
| [Environment]::SetEnvironmentVariable("PwshPath", 'preview', "Process") | ||
| [Environment]::SetEnvironmentVariable("PwshPath", "[$productDirectoryName]preview", "Process") | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @TravisEz13 Non-blocking comment: Would it not be cleaner if a the variable was declared directly here to not convolute the script with WiX syntax?
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This variable was already there and only used for this purpose. I don't think I'm getting the meaning of your statement.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I do think there is probably a cleaner way of doing this. Like refering to the preview directory by name, but the goal here was to make a quick change that would not require a lot of re-testing for the 6.1.0 release.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
[Environment]::SetEnvironmentVariable("PwshPath", (Join-Path $productDirectoryName 'preview'), "Process")
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm fine with that change for 6.2. |
||
| [Environment]::SetEnvironmentVariable("UpgradeCodeX64", '39243d76-adaf-42b1-94fb-16ecf83237c8', "Process") | ||
| [Environment]::SetEnvironmentVariable("UpgradeCodeX86", '86abcfbd-1ccc-4a88-b8b2-0facfde29094', "Process") | ||
| [Environment]::SetEnvironmentVariable("IconPath", 'assets\Powershell_av_colors.ico', "Process") | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just curious on why we are making these changes. It looks to me this change doesn't change the behavior --
Value="[$(var.ProductDirectoryName)]$(var.PwshPath)"basically does the same before the change, isn't it?Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The variable is set to empty (meaning to delete the variable) in the non-preview case and the build fails