Closed TimMangan closed 4 years ago
Yo. About scripts. It came to my attention that the scripts run outside of the container when PSF is built using release mode. I modified the code to make the attribute list closer to CreateProcess. Now Powershell should always launch inside the container.
You mention changes to help with scripts but I don't see it in your changes. Are there any code changes related to scripts?
Yo. About scripts. It came to my attention that the scripts run outside of the container when PSF is built using release mode. I modified the code to make the attribute list closer to CreateProcess. Now Powershell should always launch inside the container. You mention changes to help with scripts but I don't see it in your changes. Are there any code changes related to scripts?
I did not attempt to solve the out of container issue. Unfortunately I included the script item in the PR description, but this is not included until the next PR. That PR will add the pseudo-environment variables to allow the script to reference files inside of the package under a %MsixPackageRoot% pseudo-variable.
I see. So, this PR has everything in it?
I see. So, this PR has everything in it?
Everything in the PR description above except for the note about scripting is in this PR. THe scripting change, plus another 4 or 5 edge case fixes for certain API calls, will be in a follow-on PR once this one clears.
This PR has three major areas of changes. Most are addressing issues found in specific applications that were recently tested. A) Changes to PsfLauncher:
Directory Iteration bug. There was a bug in the launcher affecting certain apps that resulted in the launcher crashing.
Arguments. Support for target command arguments involving filepaths that are part of the package. We introduce a new pseudo-variable %MsixPackageRoot% that you can use in the config.json in the arguments field. The launcher will resolve this and start the command with the mounted path of the package (which could be different on different systems).
Shell Launches. Last year I added support for shortcuts to files that were not exe files by using a Shell launch. Unfortunately these shell launches run outside of the container, which is OK in some cases but not in others. The Shell launches will now attempt a technique recommended by Microsoft to launch these inside the container. These changes are now in place, but ultimately the MSIX Runtime still launches it externally. The changes do no harm so they are going in hoping that we can get a future change to the runtime to accommodate. Microsoft has not committed to anything on this yet, but see the scripting issue below.
Scripting Changes. NOTE: THIS CHANGE IS NOT INCLUDED IN THIS PR. IT WILL BE IN A FUTURE PR:
B) Changes to FileRedirectionFixup:
C) Changes to Tracing/Logging: