mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-22 09:45:41 +00:00
3a385c46db
MozReview-Commit-ID: FxuwGLYef5v --HG-- extra : rebase_source : e526562574050eba6b77b464f559e2c95d6c8c3a
30 lines
751 B
JavaScript
30 lines
751 B
JavaScript
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
|
|
|
/* eslint-env node */
|
|
|
|
"use strict";
|
|
|
|
const fs = require("fs");
|
|
const path = require("path");
|
|
|
|
function getConfig() {
|
|
if (process.env.TARGET === "firefox-panel") {
|
|
return require("../configs/firefox-panel.json");
|
|
}
|
|
|
|
const developmentConfig = require("../configs/development.json");
|
|
|
|
let localConfig = {};
|
|
if (fs.existsSync(path.resolve(__dirname, "../configs/local.json"))) {
|
|
localConfig = require("../configs/local.json");
|
|
}
|
|
|
|
return Object.assign({}, developmentConfig, localConfig);
|
|
}
|
|
|
|
module.exports = {
|
|
getConfig,
|
|
};
|