33 * directory. It is only for use in local development, and sets the --baseurl
44 * option to override the production-only baseurl in _config.yml.
55 */
6+ /* eslint-disable no-console */
67'use strict' ;
78
89const path = require ( 'path' ) ;
@@ -13,24 +14,24 @@ const argv = require( 'minimist' )( process.argv.slice( 2 ) );
1314const docsDir = path . resolve ( __dirname , '../documentation' ) ;
1415
1516if ( argv . install || argv . i ) {
16- // Install the ruby bundle needed to run jekyll
17- const server = spawn ( 'bundle' , [ 'install' ] , {
18- cwd : docsDir ,
19- stdio : 'inherit'
20- } ) ;
17+ // Install the ruby bundle needed to run jekyll
18+ const server = spawn ( 'bundle' , [ 'install' ] , {
19+ cwd : docsDir ,
20+ stdio : 'inherit' ,
21+ } ) ;
2122
22- server . on ( 'error' , err => console . error ( err ) ) ;
23+ server . on ( 'error' , err => console . error ( err ) ) ;
2324} else {
24- // Start the server in local dev mode
25- const bundleOptions = [ 'exec' , 'jekyll' , 'serve' , '--baseurl' , '' ] ;
26- if ( argv . host ) {
27- bundleOptions . push ( '--host' , argv . host ) ;
28- }
25+ // Start the server in local dev mode
26+ const bundleOptions = [ 'exec' , 'jekyll' , 'serve' , '--baseurl' , '' ] ;
27+ if ( argv . host ) {
28+ bundleOptions . push ( '--host' , argv . host ) ;
29+ }
2930
30- const server = spawn ( 'bundle' , bundleOptions , {
31- cwd : docsDir ,
32- stdio : 'inherit'
33- } ) ;
31+ const server = spawn ( 'bundle' , bundleOptions , {
32+ cwd : docsDir ,
33+ stdio : 'inherit' ,
34+ } ) ;
3435
35- server . on ( 'error' , err => console . error ( err ) ) ;
36+ server . on ( 'error' , err => console . error ( err ) ) ;
3637}
0 commit comments