Skip to content

Commit

Permalink
Add support for LEGENDARY_CONFIG_PATH env
Browse files Browse the repository at this point in the history
  • Loading branch information
hawkeye116477 committed Apr 3, 2024
1 parent 2712aa7 commit a9c5197
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/LegendaryLauncher.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
using System.Reflection;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using System.Windows;

namespace LegendaryLibraryNS
{
Expand Down Expand Up @@ -42,6 +41,11 @@ public static string ConfigPath
legendaryConfigPath = heroicLegendaryConfigPath;
}
}
var envLegendaryConfigPath = Environment.GetEnvironmentVariable("LEGENDARY_CONFIG_PATH");
if (!envLegendaryConfigPath.IsNullOrWhiteSpace() && Directory.Exists(envLegendaryConfigPath))
{
legendaryConfigPath = envLegendaryConfigPath;
}
return legendaryConfigPath;
}
}
Expand Down

0 comments on commit a9c5197

Please sign in to comment.