diff --git a/AvantGarde/Loading/RemoteLoader.cs b/AvantGarde/Loading/RemoteLoader.cs index 3daa80c..c044af7 100644 --- a/AvantGarde/Loading/RemoteLoader.cs +++ b/AvantGarde/Loading/RemoteLoader.cs @@ -158,10 +158,15 @@ public static PathItem FindDesignerHost(string? version) // ~/.nuget/packages/avalonia//tools/netcoreapp2.0/designer/Avalonia.Designer.HostApp.dll if (!string.IsNullOrWhiteSpace(version)) { - string src = Environment.GetFolderPath(Environment.SpecialFolder.UserProfile); + string? src = Environment.GetEnvironmentVariable("NUGET_PACKAGES"); + + if (string.IsNullOrEmpty(src)) + { + src = Environment.GetFolderPath(Environment.SpecialFolder.UserProfile); + src = Path.Combine(src, ".nuget"); + src = Path.Combine(src, "packages"); + } - src = Path.Combine(src, ".nuget"); - src = Path.Combine(src, "packages"); src = Path.Combine(src, "avalonia"); src = Path.Combine(src, version); src = Path.Combine(src, "tools");