@@ -74,10 +74,14 @@ const program = new commander.Command(packageJson.name)
7474 ) ;
7575 console . log ( ` - a specific npm version: ${ chalk . green ( '0.8.2' ) } ` ) ;
7676 console . log (
77- ` - a custom fork published on npm: ${ chalk . green ( 'my-react-scripts' ) } `
77+ ` - a custom fork published on npm: ${ chalk . green (
78+ 'my-react-scripts'
79+ ) } `
7880 ) ;
7981 console . log (
80- ` - a .tgz archive: ${ chalk . green ( 'https://mysite.com/my-react-scripts-0.8.2.tgz' ) } `
82+ ` - a .tgz archive: ${ chalk . green (
83+ 'https://mysite.com/my-react-scripts-0.8.2.tgz'
84+ ) } `
8185 ) ;
8286 console . log (
8387 ` It is not needed unless you specifically want to use a fork.`
@@ -87,7 +91,9 @@ const program = new commander.Command(packageJson.name)
8791 ` If you have any problems, do not hesitate to file an issue:`
8892 ) ;
8993 console . log (
90- ` ${ chalk . cyan ( 'https://github.com/facebookincubator/create-react-app/issues/new' ) } `
94+ ` ${ chalk . cyan (
95+ 'https://github.com/facebookincubator/create-react-app/issues/new'
96+ ) } `
9197 ) ;
9298 console . log ( ) ;
9399 } )
@@ -258,15 +264,19 @@ function run(
258264
259265 console . log ( 'Installing packages. This might take a couple of minutes.' ) ;
260266 getPackageName ( packageToInstall )
261- . then ( packageName => checkIfOnline ( useYarn ) . then ( isOnline => ( {
262- isOnline : isOnline ,
263- packageName : packageName ,
264- } ) ) )
267+ . then ( packageName =>
268+ checkIfOnline ( useYarn ) . then ( isOnline => ( {
269+ isOnline : isOnline ,
270+ packageName : packageName ,
271+ } ) )
272+ )
265273 . then ( info => {
266274 const isOnline = info . isOnline ;
267275 const packageName = info . packageName ;
268276 console . log (
269- `Installing ${ chalk . cyan ( 'react' ) } , ${ chalk . cyan ( 'react-dom' ) } , and ${ chalk . cyan ( packageName ) } ...`
277+ `Installing ${ chalk . cyan ( 'react' ) } , ${ chalk . cyan (
278+ 'react-dom'
279+ ) } , and ${ chalk . cyan ( packageName ) } ...`
270280 ) ;
271281 console . log ( ) ;
272282
@@ -334,7 +344,9 @@ function run(
334344 if ( ! remainingFiles . length ) {
335345 // Delete target folder if empty
336346 console . log (
337- `Deleting ${ chalk . cyan ( `${ appName } /` ) } from ${ chalk . cyan ( path . resolve ( root , '..' ) ) } `
347+ `Deleting ${ chalk . cyan ( `${ appName } /` ) } from ${ chalk . cyan (
348+ path . resolve ( root , '..' )
349+ ) } `
338350 ) ;
339351 process . chdir ( path . resolve ( root , '..' ) ) ;
340352 fs . removeSync ( path . join ( root ) ) ;
@@ -422,7 +434,9 @@ function getPackageName(installPackage) {
422434 / ^ .+ \/ ( .+ ?) (?: - \d + .+ ) ? \. t g z $ /
423435 ) [ 1 ] ;
424436 console . log (
425- `Based on the filename, assuming it is "${ chalk . cyan ( assumedProjectName ) } "`
437+ `Based on the filename, assuming it is "${ chalk . cyan (
438+ assumedProjectName
439+ ) } "`
426440 ) ;
427441 return Promise . resolve ( assumedProjectName ) ;
428442 } ) ;
@@ -485,7 +499,9 @@ function checkAppName(appName) {
485499 const validationResult = validateProjectName ( appName ) ;
486500 if ( ! validationResult . validForNewPackages ) {
487501 console . error (
488- `Could not create a project called ${ chalk . red ( `"${ appName } "` ) } because of npm naming restrictions:`
502+ `Could not create a project called ${ chalk . red (
503+ `"${ appName } "`
504+ ) } because of npm naming restrictions:`
489505 ) ;
490506 printValidationResults ( validationResult . errors ) ;
491507 printValidationResults ( validationResult . warnings ) ;
@@ -497,7 +513,9 @@ function checkAppName(appName) {
497513 if ( dependencies . indexOf ( appName ) >= 0 ) {
498514 console . error (
499515 chalk . red (
500- `We cannot create a project called ${ chalk . green ( appName ) } because a dependency with the same name exists.\n` +
516+ `We cannot create a project called ${ chalk . green (
517+ appName
518+ ) } because a dependency with the same name exists.\n` +
501519 `Due to the way npm works, the following names are not allowed:\n\n`
502520 ) +
503521 chalk . cyan ( dependencies . map ( depName => ` ${ depName } ` ) . join ( '\n' ) ) +
@@ -519,7 +537,9 @@ function makeCaretRange(dependencies, name) {
519537
520538 if ( ! semver . validRange ( patchedVersion ) ) {
521539 console . error (
522- `Unable to patch ${ name } dependency version because version ${ chalk . red ( version ) } will become invalid ${ chalk . red ( patchedVersion ) } `
540+ `Unable to patch ${ name } dependency version because version ${ chalk . red (
541+ version
542+ ) } will become invalid ${ chalk . red ( patchedVersion ) } `
523543 ) ;
524544 patchedVersion = version ;
525545 }
0 commit comments