[wix-devs] Burn support for WM_SETTINGSCHANGED to refresh environment variables

Blair Murri osito at live.com
Sat Apr 13 07:12:06 PDT 2019


2. user overrides system, except for PATH, where user prepends system.

Get Outlook for Android<https://aka.ms/ghei36>

________________________________
From: wix-devs <wix-devs-bounces at lists.wixtoolset.org> on behalf of Rob Mensching via wix-devs <wix-devs at lists.wixtoolset.org>
Sent: Friday, April 12, 2019 2:37:55 PM
To: Sean Farrow; WiX Toolset Developer Mailing List
Cc: Rob Mensching
Subject: Re: [wix-devs] Burn support for WM_SETTINGSCHANGED to refresh environment variables

1. System and user variables should be merged into a single view. I _think_ user overwrites system except for PATH that merges them.

2. The behavior should match what the system does when it creates the process. My bet is that it does not expand values but would be good to validate the behavior.

Regards,

  Rob Mensching
  CEO
  FireGiant
_______________________________________________________________
 FireGiant  |  Dedicated support for the WiX toolset  |  http://www.firegiant.com/

-----Original Message-----
From: Sean Farrow <sean.farrow at seanfarrow.co.uk>
Sent: Friday, April 12, 2019 1:36 PM
To: Rob Mensching <rob at firegiant.com>; WiX Toolset Developer Mailing List <wix-devs at lists.wixtoolset.org>
Subject: RE: Burn support for WM_SETTINGSCHANGED to refresh environment variables

Hi,

Should we export separate functions to retrieve the user and system variables as well as a function to refresh them for use in the WM_SETTINGSCHANGED code itself?
Would it also be useful to have a function to expand variables? I noticed that pathutil.cpp expands variables so wondered whether it was worth centralising this code in case any other code needed it.

Cheers
Sean.
-----Original Message-----
From: Rob Mensching <rob at firegiant.com>
Sent: 12 April 2019 17:24
To: WiX Toolset Developer Mailing List <wix-devs at lists.wixtoolset.org>
Cc: Sean Farrow <sean.farrow at seanfarrow.co.uk>
Subject: RE: Burn support for WM_SETTINGSCHANGED to refresh environment variables

1. It has to be added to the engine (stub) since that is the process starting the ExePackage processes. Fortunately, there is already a message loop in the engine for handling shutdown messages.

2. It might be nice to add to the native BA but I'm not sure how useful that would be in practice since the native BA wouldn't be able to do anything with it.

3. Managed BA doesn't own the message loop so it isn't "in the loop" (ha, ha) to handle WM_SETTINGSCHANGED.

To get started, add an "EnvRefresh()" function (or better name) to a new envutil.cpp in https://github.com/wixtoolset/dutil. I expect that will be the hardest part. Then add the WM_SETTINGSCHANGED switch case to the message handling in the stub and call the new function.

That _should_ do it.

Regards,

  Rob Mensching
  CEO
  FireGiant
_______________________________________________________________
 FireGiant  |  Dedicated support for the WiX toolset  |  http://www.firegiant.com/

-----Original Message-----
From: wix-devs <wix-devs-bounces at lists.wixtoolset.org> On Behalf Of Sean Farrow via wix-devs
Sent: Friday, April 12, 2019 5:16 AM
To: WiX Toolset Developer Mailing List <wix-devs at lists.wixtoolset.org>
Cc: Sean Farrow <sean.farrow at seanfarrow.co.uk>
Subject: [wix-devs] Burn support for WM_SETTINGSCHANGED to refresh environment variables

Hi,

Just following up to start the design discussion for this feature as requested.
Do we want to add this to both the managed and unmanaged bootstrappers?
Or, can we get away with just adding it to the stub?
Cheers
Sean.
____________________________________________________________________
WiX Toolset Developer Mailing List provided by FireGiant http://www.firegiant.com/
____________________________________________________________________
WiX Toolset Developer Mailing List provided by FireGiant http://www.firegiant.com/



More information about the wix-devs mailing list