diff --git a/src/core/Microsoft.PowerToys.Settings.UI.Lib/Utilities/Helper.cs b/src/core/Microsoft.PowerToys.Settings.UI.Lib/Utilities/Helper.cs index 273914b494..6d927bcee4 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI.Lib/Utilities/Helper.cs +++ b/src/core/Microsoft.PowerToys.Settings.UI.Lib/Utilities/Helper.cs @@ -47,8 +47,15 @@ namespace Microsoft.PowerToys.Settings.UI.Lib.Utilities public static FileSystemWatcher GetFileWatcher(string moduleName, string fileName, Action onChangedCallback) { + var path = Path.Combine(LocalApplicationDataFolder(), $"Microsoft\\PowerToys\\{moduleName}"); + + if (!Directory.Exists(path)) + { + Directory.CreateDirectory(path); + } + var watcher = new FileSystemWatcher(); - watcher.Path = Path.Combine(LocalApplicationDataFolder(), $"Microsoft\\PowerToys\\{moduleName}"); + watcher.Path = path; watcher.Filter = fileName; watcher.NotifyFilter = NotifyFilters.LastWrite; watcher.Changed += (o, e) => onChangedCallback(); diff --git a/src/modules/launcher/Plugins/Wox.Plugin.Program/Programs/Win32.cs b/src/modules/launcher/Plugins/Wox.Plugin.Program/Programs/Win32.cs index 6ac1ebdff2..3dc0202d83 100644 --- a/src/modules/launcher/Plugins/Wox.Plugin.Program/Programs/Win32.cs +++ b/src/modules/launcher/Plugins/Wox.Plugin.Program/Programs/Win32.cs @@ -61,7 +61,7 @@ namespace Wox.Plugin.Program.Programs { var info = new ProcessStartInfo { - FileName = FullPath, + FileName = LnkResolvedPath ?? FullPath, WorkingDirectory = ParentDirectory, UseShellExecute = true };