mirror of
https://github.com/Llewellynvdm/nativefier.git
synced 2024-11-11 07:41:04 +00:00
Fix bug where icns conversion fails silently
This commit is contained in:
parent
c8d6cef815
commit
e2d762b721
@ -26,11 +26,16 @@ function pngToIcns(pngSrc, icnsDest, callback) {
|
||||
}
|
||||
|
||||
shell.exec(`${PNG_TO_ICNS_BIN_PATH} ${pngSrc} ${icnsDest}`, {silent: true}, (exitCode, stdOut, stdError) => {
|
||||
if (exitCode) {
|
||||
callback({
|
||||
stdOut: stdOut,
|
||||
stdError: stdError
|
||||
}, pngSrc);
|
||||
if (stdOut.includes('icon.iconset:error') || exitCode) {
|
||||
if (exitCode) {
|
||||
callback({
|
||||
stdOut: stdOut,
|
||||
stdError: stdError
|
||||
}, pngSrc);
|
||||
return;
|
||||
}
|
||||
|
||||
callback(stdOut, pngSrc);
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user