From d432b0560f969f82243ff7237d715bd92659898d Mon Sep 17 00:00:00 2001 From: Firaenix Date: Wed, 27 Jul 2016 20:13:45 +1000 Subject: [PATCH] Added Elementary OS case to switch statement --- src/platform.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/platform.ts b/src/platform.ts index d1a658ed54..b21486a4f6 100644 --- a/src/platform.ts +++ b/src/platform.ts @@ -80,6 +80,16 @@ export function getCurrentPlatform() { case 'ol': // Oracle Linux is binary compatible with CentOS return Platform.CentOS; + case 'elementary OS': + const eOSVersionId = getValue("VERSION_ID"); + if (eOSVersionId.startsWith("0.3")) { + // Elementary OS 0.3 Freya is binary compatible with Ubuntu 14.04 + return Platform.Ubuntu14; + } + else if (eOSVersionId.startsWith("0.4")) { + // Elementary OS 0.4 Loki is binary compatible with Ubuntu 16.04 + return Platform.Ubuntu16; + } } }