mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
We "update the package catalog", not package metadata, not refresh
This commit is contained in:
@@ -750,14 +750,14 @@ _.extend(RemoteCatalog.prototype, {
|
||||
Console.debug("lastSync = ", lastSync);
|
||||
if (lastSync && lastSync.timestamp) {
|
||||
if ((Date.now() - lastSync.timestamp) < options.maxAge) {
|
||||
Console.debug("Catalog is sufficiently up-to-date; not refreshing\n");
|
||||
Console.debug("Package catalog is sufficiently up-to-date; not updating\n");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
var updateResult = {};
|
||||
buildmessage.enterJob({ title: 'Refreshing package metadata.' }, function () {
|
||||
buildmessage.enterJob({ title: 'Updating package catalog.' }, function () {
|
||||
updateResult = packageClient.updateServerPackageData(self);
|
||||
});
|
||||
|
||||
|
||||
@@ -67,20 +67,20 @@ var doOrDie = exports.doOrDie = function (options, f) {
|
||||
|
||||
};
|
||||
var refreshOfficialCatalogOrDie = function (options) {
|
||||
doOrDie({title: 'Refreshing package catalog'}, function () {
|
||||
doOrDie({title: 'Updating package catalog'}, function () {
|
||||
try {
|
||||
catalog.official.refresh(options);
|
||||
} catch (err) {
|
||||
buildmessage.error("Unable to refresh package catalog", err);
|
||||
buildmessage.error("Unable to update the package catalog", err);
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
var explainIfRefreshFailed = function (command) {
|
||||
if (catalog.official.offline) {
|
||||
Console.info("(But we're offline, so we didn't update the local catalog, so it might exist)");
|
||||
Console.info("(But we're offline, so we didn't update the package catalog, so it might exist)");
|
||||
} else if (command.catalogRefresh.refreshFailed) {
|
||||
Console.info("(But the update of the local catalog failed, so it might exist)");
|
||||
Console.info("(But the update of the package catalog failed, so it might exist)");
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -1232,7 +1232,7 @@ commandName + ": You're not in a Meteor project directory.\n" +
|
||||
throw new Error("Command does not define catalogRefresh");
|
||||
}
|
||||
if (catalogRefreshStrategy && catalogRefreshStrategy.beforeCommand) {
|
||||
var messages = buildmessage.capture({title: 'Refreshing package catalog'}, function () {
|
||||
var messages = buildmessage.capture({title: 'Updating package catalog'}, function () {
|
||||
catalogRefreshStrategy.beforeCommand();
|
||||
});
|
||||
if (messages.hasMessages()) {
|
||||
|
||||
@@ -430,7 +430,7 @@ _.extend(AppRunner.prototype, {
|
||||
} catch (err) {
|
||||
// XXX: Should we throw here?
|
||||
// XXX: Should we remove this entirely?
|
||||
Console.debug("Ignoring error refreshing package catalog", err);
|
||||
Console.debug("Ignoring error updating package catalog", err);
|
||||
}
|
||||
});
|
||||
if (refreshMessages.hasMessages()) {
|
||||
|
||||
Reference in New Issue
Block a user