1
0
mirror of https://github.com/mifi/lossless-cut.git synced 2024-11-22 02:12:30 +01:00

fix mac and windows

This commit is contained in:
Mikael Finstad 2023-09-24 13:06:33 +08:00
parent 9b1ea4b66e
commit 373fdaf93e

View File

@ -26,7 +26,14 @@ function getFfPath(cmd) {
const exeName = isWindows ? `${cmd}.exe` : cmd; const exeName = isWindows ? `${cmd}.exe` : cmd;
if (customFfPath) return join(customFfPath, exeName); if (customFfPath) return join(customFfPath, exeName);
if (isDev) return join('ffmpeg', `${platform}-${arch}/lib`, exeName);
if (isDev) {
const components = ['ffmpeg'];
if (isWindows || isLinux) components.push('lib');
components.push(exeName);
return join(...components);
}
return join(process.resourcesPath, exeName); return join(process.resourcesPath, exeName);
} }