diff --git a/lib/config.js b/lib/config.js index 3fb937d..ec7aa92 100644 --- a/lib/config.js +++ b/lib/config.js @@ -25,7 +25,11 @@ export function getMergedConfig(dir, home) { export function getConfig(configType, dir) { const configPath = getConfigPath(configType, dir); - return readJson(configPath); + try { + return readJson(configPath); + } catch (cause) { + throw new Error('Unable to parse config file ' + configPath, { cause }); + } }; export function getConfigPath(configType, dir) {