From 5352b8cf341fc1dde8273ccdd081f1e5fa5fe391 Mon Sep 17 00:00:00 2001 From: develar Date: Sat, 11 Feb 2017 12:05:40 +0100 Subject: [PATCH] feat(linux): assert that linux.icon is a directory Close #1242 --- packages/electron-builder/src/targets/LinuxTargetHelper.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/electron-builder/src/targets/LinuxTargetHelper.ts b/packages/electron-builder/src/targets/LinuxTargetHelper.ts index 51208d6911b..343e50ef728 100644 --- a/packages/electron-builder/src/targets/LinuxTargetHelper.ts +++ b/packages/electron-builder/src/targets/LinuxTargetHelper.ts @@ -27,6 +27,9 @@ export class LinuxTargetHelper { if (e.code === "ENOENT") { throw new Error(`Icon set directory ${iconDir} doesn't exist`) } + else if (e.code === "ENOTDIR") { + throw new Error(`linux.icon must be set to an icon set directory, but ${iconDir} is not a directory. Please see https://github.com/electron-userland/electron-builder/wiki/Options#LinuxBuildOptions-icon`) + } else { throw e }