Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Meta
create-react-app
Commits
955ea330
Commit
955ea330
authored
8 years ago
by
Dan Abramov
Browse files
Options
Download
Email Patches
Plain Diff
Make messages windows-friendly
parent
bc6f4e19
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
global-cli/index.js
+1
-1
global-cli/index.js
scripts/build.js
+6
-4
scripts/build.js
with
7 additions
and
5 deletions
+7
-5
global-cli/index.js
+
1
-
1
View file @
955ea330
...
@@ -91,7 +91,7 @@ function createApp(name, verbose, version) {
...
@@ -91,7 +91,7 @@ function createApp(name, verbose, version) {
fs
.
writeFileSync
(
path
.
join
(
root
,
'
package.json
'
),
JSON
.
stringify
(
packageJson
));
fs
.
writeFileSync
(
path
.
join
(
root
,
'
package.json
'
),
JSON
.
stringify
(
packageJson
));
process
.
chdir
(
root
);
process
.
chdir
(
root
);
console
.
log
(
'
Installing packages. This might take a couple minutes.
⌛
'
);
console
.
log
(
'
Installing packages. This might take a couple minutes.
'
);
console
.
log
(
'
Installing react-scripts from npm...
'
);
console
.
log
(
'
Installing react-scripts from npm...
'
);
run
(
root
,
appName
,
version
,
verbose
);
run
(
root
,
appName
,
version
,
verbose
);
...
...
This diff is collapsed.
Click to expand it.
scripts/build.js
+
6
-
4
View file @
955ea330
...
@@ -26,12 +26,14 @@ webpack(config).run(function(err, stats) {
...
@@ -26,12 +26,14 @@ webpack(config).run(function(err, stats) {
process
.
exit
(
1
);
process
.
exit
(
1
);
}
}
var
openCommand
=
process
.
platform
===
'
win32
'
?
'
start
'
:
'
open
'
;
console
.
log
(
'
Successfully generated a bundle in the build folder!
'
);
console
.
log
(
'
Successfully generated a bundle in the build folder!
'
);
console
.
log
();
console
.
log
();
console
.
log
(
'
You can now serve it with any static server:
'
);
console
.
log
(
'
You can now serve it with any static server
, for example
:
'
);
console
.
log
(
'
cd build
'
);
console
.
log
(
'
cd build
'
);
console
.
log
(
'
python -m SimpleHTTPServer 9000
'
);
console
.
log
(
'
npm install -g http-server
'
);
console
.
log
(
'
open http://localhost:9000
'
);
console
.
log
(
'
hs
'
);
console
.
log
(
'
'
+
openCommand
+
'
http://localhost:8080
'
);
console
.
log
();
console
.
log
();
console
.
log
(
'
It
is optimized and ready to be deployed
for
production.
'
);
console
.
log
(
'
The bundle
is optimized and ready to be deployed
to
production.
'
);
});
});
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment