Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Commit

Permalink
Merge pull request #1561 from atom/dw-fix-nightly-tests
Browse files Browse the repository at this point in the history
Add support for nightly channel
  • Loading branch information
daviwil committed Jul 3, 2018
1 parent 380a503 commit 094e3b5
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions lib/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,18 @@ export function getPackageRoot() {
}
}

function getAtomAppName() {
const match = atom.getVersion().match(/beta|nightly/)
if (match) {
return `Atom ${match[0].charAt(0).toUpperCase() + match[0].slice(1)} Helper`
}

return 'Atom Helper'
}

export function getAtomHelperPath() {
if (process.platform === 'darwin') {
const beta = atom.appVersion.match(/-beta/);
const appName = beta ? 'Atom Beta Helper' : 'Atom Helper';
const appName = getAtomAppName()
return path.resolve(process.resourcesPath, '..', 'Frameworks',
`${appName}.app`, 'Contents', 'MacOS', appName);
} else {
Expand Down

0 comments on commit 094e3b5

Please sign in to comment.