File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
packages/api/core/src/util Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -124,7 +124,14 @@ export default async (dir: string): Promise<ResolvedForgeConfig> => {
124124 forgeConfig = packageJSON . config && packageJSON . config . forge ? packageJSON . config . forge : null ;
125125 }
126126
127- if ( ! forgeConfig || typeof forgeConfig === 'string' ) {
127+ if ( forgeConfig && typeof forgeConfig === 'string' ) {
128+ const pathToConfig = path . resolve ( dir , forgeConfig ) ;
129+ if ( ! rechoir . prepare ( interpret . extensions , pathToConfig , dir ) ) {
130+ throw new Error ( `Not found interpret for config file[${ pathToConfig } ]` ) ;
131+ }
132+ }
133+
134+ if ( ! forgeConfig ) {
128135 for ( const extension of [ '.js' , ...Object . keys ( interpret . extensions ) ] ) {
129136 const pathToConfig = path . resolve ( dir , `forge.config${ extension } ` ) ;
130137 if ( await fs . pathExists ( pathToConfig ) ) {
You can’t perform that action at this time.
0 commit comments