Rename --mobile-server to --server for 'meteor build'.

This commit is contained in:
Emily Stark
2014-09-29 18:38:52 -07:00
parent a403c54bf8
commit 59db2ff04b
3 changed files with 11 additions and 11 deletions

View File

@@ -572,7 +572,7 @@ var buildCommands = {
debug: { type: Boolean },
directory: { type: Boolean },
architecture: { type: String },
"mobile-server": { type: String },
server: { type: String },
// XXX COMPAT WITH 0.9.2.2
"mobile-port": { type: String },
settings: { type: String },
@@ -628,7 +628,7 @@ var buildCommand = function (options) {
if (! _.isEmpty(mobilePlatforms)) {
// XXX COMPAT WITH 0.9.2.2 -- the mobile-port is deprecated
var mobileServer = options["mobile-server"] ||
var mobileServer = options.server ||
options["mobile-port"];
if (mobileServer) {
@@ -646,10 +646,10 @@ var buildCommand = function (options) {
return 1;
}
} else {
// For Cordova builds, require '--mobile-server'.
// For Cordova builds, require '--server'.
// XXX better error message?
process.stderr.write(
"Supply the server hostname and port in the --mobile-server option\n" +
"Supply the server hostname and port in the --server option\n" +
"for mobile app builds.\n");
return 1;
}

View File

@@ -187,7 +187,7 @@ Deprecated command. Use 'build' instead.
>>> build
Outputs builds for all targeted platforms.
Usage: meteor build <output path> [--debug] [--directory]
[--settings settings.json] [--mobile-server http://example.com:3000]
[--settings settings.json] [--server http://example.com:3000]
Package this project up for deployment. The output is a directory with several
build artifacts:
@@ -207,9 +207,9 @@ Options:
it will be recursively deleted first.
--settings set optional data for Meteor.settings for the build-time
settings (such as settings required by Cordova plugins).
--mobile-server Location where mobile builds connect to the Meteor server.
--server Location where mobile builds connect to the Meteor server.
Defaults to localhost:3000. Can include a URL scheme
(for example, --mobile-server=https://example.com:443).
(for example, --server=https://example.com:443).
>>> mongo

View File

@@ -36,22 +36,22 @@ selftest.define("cordova builds with server options", ["slow"], function () {
run = s.run("build", ".");
run.waitSecs(90);
run.matchErr(
"Supply the server hostname and port in the --mobile-server option");
"Supply the server hostname and port in the --server option");
run.expectExit(1);
run = s.run("build", ".", "--mobile-server", "5000");
run = s.run("build", ".", "--server", "5000");
run.waitSecs(90);
run.expectExit(0);
checkMobileServer(s, "http://localhost:5000");
cleanUpBuild(s);
run = s.run("build", ".", "--mobile-server", "https://example.com:5000");
run = s.run("build", ".", "--server", "https://example.com:5000");
run.waitSecs(90);
run.expectExit(0);
checkMobileServer(s, "https://example.com:5000");
cleanUpBuild(s);
run = s.run("build", ".", "--mobile-server", "example.com:5000");
run = s.run("build", ".", "--server", "example.com:5000");
run.waitSecs(90);
run.expectExit(0);
checkMobileServer(s, "http://example.com:5000");