Skip to content
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

fix: ForceDisableWSL wasn't honored #256

Merged
merged 2 commits into from
Jul 21, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ The Bootstrapper tooling will generate two folders `_compressed_gz` and `_compre
When building an application, place [the following file](src/Uno.Wasm.Sample/wwwroot/web.config) in the `wwwroot` folder to automatically enable the use of pre-compressed files.

The parameters for the compression are as follows:
- `WasmShellGenerateCompressedFiles` which can be `true` of `false`. This property is ignored when building `MonoRuntimeDebuggerEnabled` is set to `true`.
- `WasmShellGenerateCompressedFiles` which can be `true` or `false`. This property is ignored when building `MonoRuntimeDebuggerEnabled` is set to `true`.
- `WasmShellCompressedExtension` is an item group which specifies which files to compress. By default `wasm`, `clr`, `js`, `css` and `html files are pre-compressed. More files can be added as follows:
```xml
<ItemGroup>
Expand Down
4 changes: 2 additions & 2 deletions src/Uno.Wasm.Bootstrap/ShellTask.cs
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ as the BrotliStream must be closed in order to signal that no more blocks are be

private (int exitCode, string output, string error) RunProcess(string executable, string parameters, string? workingDirectory = null)
{
if (IsWSLRequired)
if (IsWSLRequired && !ForceDisableWSL)
{
var unixPath = AlignPath(executable, escape: true);
var monoPath = executable.EndsWith(".exe") ? "mono" : "";
Expand Down Expand Up @@ -485,7 +485,7 @@ as the BrotliStream must be closed in order to signal that no more blocks are be

private string AlignPath(string path, bool escape = false)
{
var output = IsWSLRequired ? $"`wslpath \"{path.Replace("\\\\?\\", "")}\"`" : path;
var output = IsWSLRequired && !ForceDisableWSL ? $"`wslpath \"{path.Replace("\\\\?\\", "")}\"`" : path;

if (escape)
{
Expand Down