Fix CLI arg routing and desktop install links

This commit is contained in:
Mohamed Boudra
2026-04-04 16:35:31 +07:00
parent c3313ff82a
commit d69fcb861d
9 changed files with 317 additions and 30 deletions
@@ -0,0 +1,24 @@
export function resolveCliInstallSourcePath(input: {
platform: NodeJS.Platform;
isPackaged: boolean;
executablePath: string;
shimPath: string;
appImagePath?: string | null;
}): string {
if (input.platform === "win32") {
return input.shimPath;
}
if (!input.isPackaged) {
return input.shimPath;
}
if (input.platform === "linux") {
const appImagePath = input.appImagePath?.trim();
if (appImagePath) {
return appImagePath;
}
}
return input.executablePath;
}