-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #52 from mazswojejzony/env-settings
LAUNCHPAD_<browser> & LAUNCHPAD_BROWSERS env vars
- Loading branch information
Showing
8 changed files
with
121 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
var _ = require('underscore'); | ||
var debug = require('debug')('launchpad:local:platform'); | ||
|
||
var platforms = { | ||
win32 : './windows', | ||
darwin : './macos', | ||
linux : './unix', | ||
freebsd : './unix', | ||
sunos : './unix' | ||
}; | ||
|
||
var platform = require(platforms[process.platform]); | ||
var envBrowsers = process.env.LAUNCHPAD_BROWSERS; | ||
var enabledBrowsers = envBrowsers ? envBrowsers.split(/\s*,\s*/) : Object.keys(platform); | ||
|
||
debug('Local platform init. Enabled browsers:', enabledBrowsers.sort().join(', ')); | ||
module.exports = _.pick(platform, enabledBrowsers); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters