File tree Expand file tree Collapse file tree 1 file changed +8
-9
lines changed
Expand file tree Collapse file tree 1 file changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -54,17 +54,16 @@ function readConfig() {
5454
5555 if ( configFilepath ) {
5656 customConfig = require ( configFilepath ) ;
57+ options = _ . merge ( { } , options , customConfig ) ;
58+ options . rootDir = path . resolve ( path . dirname ( configFilepath ) , options . rootDir ) ;
59+ } else {
60+ options . _rootDir = config . rootDir ;
61+ options . rootDir = path . join ( pathToSourceJSUser , options . rootDir ) ;
62+
63+ options . _styleguideDir = config . styleguideDir ;
64+ options . styleguideDir = path . join ( pathToSourceJSUser , options . styleguideDir ) ;
5765 }
5866
59- options = _ . merge ( { } , options , customConfig ) ;
60-
61- // Extend config
62- options . _rootDir = config . rootDir ;
63- options . rootDir = path . join ( pathToSourceJSUser , config . rootDir ) ;
64-
65- options . _styleguideDir = config . styleguideDir ;
66- options . styleguideDir = path . join ( pathToSourceJSUser , config . styleguideDir ) ;
67-
6867 validateConfig ( options ) ;
6968
7069 if ( options . verbose ) {
You can’t perform that action at this time.
0 commit comments