feat: make it possible to select shortcuts (.lnk)

This commit is contained in:
Zamitto
2024-06-27 18:05:07 -03:00
parent 82f72071f9
commit 7be626b3dd
5 changed files with 27 additions and 5 deletions

View File

@@ -0,0 +1,10 @@
import { shell } from "electron";
export const parseExecutablePath = (path: string) => {
if (process.platform === "win32" && path.endsWith(".lnk")) {
const { target } = shell.readShortcutLink(path);
return target;
}
return path;
};