fix(package): update cosmiconfig to version 5.0.0
This commit is contained in:
committed by
Pierre Vanduynslager
parent
1ed466e337
commit
349b2e8d77
+12
-1
@@ -7,8 +7,19 @@ const {repoUrl} = require('./git');
|
||||
const PLUGINS_DEFINITIONS = require('./definitions/plugins');
|
||||
const plugins = require('./plugins');
|
||||
|
||||
const CONFIG_NAME = 'release';
|
||||
const CONFIG_FILES = [
|
||||
'package.json',
|
||||
`.${CONFIG_NAME}rc`,
|
||||
`.${CONFIG_NAME}rc.json`,
|
||||
`.${CONFIG_NAME}rc.yaml`,
|
||||
`.${CONFIG_NAME}rc.yml`,
|
||||
`.${CONFIG_NAME}rc.js`,
|
||||
`${CONFIG_NAME}.config.js`,
|
||||
];
|
||||
|
||||
module.exports = async (opts, logger) => {
|
||||
const {config} = (await cosmiconfig('release', {rcExtensions: true}).load(process.cwd())) || {};
|
||||
const {config} = (await cosmiconfig(CONFIG_NAME, {searchPlaces: CONFIG_FILES}).search()) || {};
|
||||
// Merge config file options and CLI/API options
|
||||
let options = {...config, ...opts};
|
||||
const pluginsPath = {};
|
||||
|
||||
Reference in New Issue
Block a user