From 43a6e0cc69b4105e81740c41d49a130377eaa30e Mon Sep 17 00:00:00 2001 From: David Wilson Date: Thu, 12 Jul 2018 12:13:57 -0700 Subject: [PATCH] Support arbitrary channel names when lauhching Atom Helper --- lib/helpers.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/helpers.js b/lib/helpers.js index 5d6fab3041b..14bc037461d 100644 --- a/lib/helpers.js +++ b/lib/helpers.js @@ -31,9 +31,10 @@ export function getPackageRoot() { } function getAtomAppName() { - const match = atom.getVersion().match(/beta|nightly/); + const match = atom.getVersion().match(/-([a-z]+)(\d+|-)/); if (match) { - return `Atom ${match[0].charAt(0).toUpperCase() + match[0].slice(1)} Helper`; + const channel = match[1] + return `Atom ${channel.charAt(0).toUpperCase() + channel.slice(1)} Helper`; } return 'Atom Helper';