Skip to content

Commit c4cac64

Browse files
Firaenixgregg-miskelly
authored andcommitted
Added Elementary OS case to switch statement (#628)
1 parent 4851f2a commit c4cac64

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/platform.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,16 @@ export function getCurrentPlatform() {
8080
case 'ol':
8181
// Oracle Linux is binary compatible with CentOS
8282
return Platform.CentOS;
83+
case 'elementary OS':
84+
const eOSVersionId = getValue("VERSION_ID");
85+
if (eOSVersionId.startsWith("0.3")) {
86+
// Elementary OS 0.3 Freya is binary compatible with Ubuntu 14.04
87+
return Platform.Ubuntu14;
88+
}
89+
else if (eOSVersionId.startsWith("0.4")) {
90+
// Elementary OS 0.4 Loki is binary compatible with Ubuntu 16.04
91+
return Platform.Ubuntu16;
92+
}
8393
}
8494
}
8595

0 commit comments

Comments
 (0)