File tree 1 file changed +7
-2
lines changed
packages/create-react-app
1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -85,6 +85,11 @@ const program = new commander.Command(packageJson.name)
85
85
'https://mysite.com/my-react-scripts-0.8.2.tgz'
86
86
) } `
87
87
) ;
88
+ console . log (
89
+ ` - a .tar.gz archive: ${ chalk . green (
90
+ 'https://mysite.com/my-react-scripts-0.8.2.tar.gz'
91
+ ) } `
92
+ ) ;
88
93
console . log (
89
94
` It is not needed unless you specifically want to use a fork.`
90
95
) ;
@@ -432,7 +437,7 @@ function extractStream(stream, dest) {
432
437
433
438
// Extract package name from tarball url or path.
434
439
function getPackageName ( installPackage ) {
435
- if ( installPackage . indexOf ( '. tgz' ) > - 1 ) {
440
+ if ( installPackage . match ( / ^ . + \. ( t g z | t a r \. g z ) $ / ) ) {
436
441
return getTemporaryDirectory ( )
437
442
. then ( obj => {
438
443
let stream ;
@@ -455,7 +460,7 @@ function getPackageName(installPackage) {
455
460
`Could not extract the package name from the archive: ${ err . message } `
456
461
) ;
457
462
const assumedProjectName = installPackage . match (
458
- / ^ .+ \/ ( .+ ?) (?: - \d + .+ ) ? \. t g z $ /
463
+ / ^ .+ \/ ( .+ ?) (?: - \d + .+ ) ? \. ( t g z | t a r \. g z ) $ /
459
464
) [ 1 ] ;
460
465
console . log (
461
466
`Based on the filename, assuming it is "${ chalk . cyan (
You can’t perform that action at this time.
0 commit comments