From e2dbb6093e485965c0d4a565ee56f87cd22c7ab7 Mon Sep 17 00:00:00 2001 From: Ben Newman Date: Fri, 8 Jul 2016 11:51:20 -0400 Subject: [PATCH] Always call updateMeteorToolSymlink after successful update. https://github.com/meteor/meteor/pull/7340#issuecomment-231254368 --- tools/cli/commands-packages.js | 3 +++ tools/packaging/updater.js | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/tools/cli/commands-packages.js b/tools/cli/commands-packages.js index c0dcfabd53..7339364972 100644 --- a/tools/cli/commands-packages.js +++ b/tools/cli/commands-packages.js @@ -24,6 +24,7 @@ var packageClient = require('../packaging/package-client.js'); var tropohouse = require('../packaging/tropohouse.js'); import * as cordova from '../cordova'; +import { updateMeteorToolSymlink } from "../packaging/updater.js"; // For each release (or package), we store a meta-record with its name, // maintainers, etc. This function takes in a name, figures out if @@ -1336,6 +1337,8 @@ var maybeUpdateRelease = function (options) { throw new Error("don't have a proper release?"); } + updateMeteorToolSymlink(true); + // If we're not in an app, then we're basically done. The only thing left to // do is print out some messages explaining what happened (and advising the // user to run update from an app). diff --git a/tools/packaging/updater.js b/tools/packaging/updater.js index 5e08a65540..d8e1eb38a5 100644 --- a/tools/packaging/updater.js +++ b/tools/packaging/updater.js @@ -152,7 +152,7 @@ var maybeShowBanners = function () { // Update ~/.meteor/meteor to point to the tool binary from the tools of the // latest recommended release on the default release track. -var updateMeteorToolSymlink = function (printErrors) { +export function updateMeteorToolSymlink(printErrors) { // Get the latest release version of METEOR. (*Always* of the default // track, not of whatever we happen to be running: we always want the tool // symlink to go to the default track.) @@ -215,4 +215,4 @@ var updateMeteorToolSymlink = function (printErrors) { tropohouse.default.linkToLatestMeteor(files.pathJoin( relativeToolPath, toolRecord.path, 'meteor')); } -}; +}