diff --git a/History.md b/History.md index 054568ed12..e5880cb630 100644 --- a/History.md +++ b/History.md @@ -1,6 +1,31 @@ ## v.NEXT -* Adds App.appendToConfig allowing custom tags in config.xml [#7307](https://github.com/meteor/meteor/pull/7307) +## v1.3.4.2 + +* The `meteor node` and `meteor npm` commands now respect + `.meteor/release` when resolving which versions of `node` and `npm` to + invoke. Note that you must `meteor update` to 1.3.4.2 before this logic + will take effect, but it will work in all app directories after + updating, even those pinned to older versions. + [#7338](https://github.com/meteor/meteor/issue/7338) + +* The Meteor installer now has the ability to resume downloads, so + installing Meteor on a spotty internet connection should be more + reliable. [#7348](https://github.com/meteor/meteor/pull/7348) + +* When running `meteor test`, shared directories are symlinked (or + junction-linked on Windows) into the temporary test directory, not + copied, leading to much faster test start times after the initial build. + The directories: `.meteor/local/{bundler-cache,isopacks,plugin-cache}` + +* `App.appendToConfig` allows adding custom tags to config.xml. + [#7307](https://github.com/meteor/meteor/pull/7307) + +* Fixed bugs: + [#7149](https://github.com/meteor/meteor/issues/7149) + [#7296](https://github.com/meteor/meteor/issues/7296) + [#7309](https://github.com/meteor/meteor/issues/7309) + [#7312](https://github.com/meteor/meteor/issues/7312) ## v1.3.4.1 diff --git a/meteor b/meteor index 9139642f5b..5e2fcaae58 100755 --- a/meteor +++ b/meteor @@ -1,6 +1,6 @@ #!/usr/bin/env bash -BUNDLE_VERSION=0.6.15 +BUNDLE_VERSION=0.6.16 # OS Check. Put here because here is where we download the precompiled # bundles that are arch specific. diff --git a/packages/autoupdate/package.js b/packages/autoupdate/package.js index ad8e00c742..5738196a10 100644 --- a/packages/autoupdate/package.js +++ b/packages/autoupdate/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "Update the client when new client code is available", - version: '1.2.10' + version: '1.2.11' }); Package.onUse(function (api) { diff --git a/packages/babel-compiler/.npm/package/npm-shrinkwrap.json b/packages/babel-compiler/.npm/package/npm-shrinkwrap.json index f66daaaa31..7ca8edd8db 100644 --- a/packages/babel-compiler/.npm/package/npm-shrinkwrap.json +++ b/packages/babel-compiler/.npm/package/npm-shrinkwrap.json @@ -21,13 +21,13 @@ "from": "ansi-styles@>=2.2.1 <3.0.0" }, "ast-types": { - "version": "0.8.16", - "resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.8.16.tgz", + "version": "0.8.17", + "resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.8.17.tgz", "from": "ast-types@>=0.8.16 <0.9.0" }, "babel-code-frame": { - "version": "6.8.0", - "resolved": "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.8.0.tgz", + "version": "6.11.0", + "resolved": "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.11.0.tgz", "from": "babel-code-frame@>=6.8.0 <7.0.0" }, "babel-core": { @@ -36,8 +36,8 @@ "from": "babel-core@>=6.9.1 <6.10.0" }, "babel-generator": { - "version": "6.10.2", - "resolved": "https://registry.npmjs.org/babel-generator/-/babel-generator-6.10.2.tgz", + "version": "6.11.0", + "resolved": "https://registry.npmjs.org/babel-generator/-/babel-generator-6.11.0.tgz", "from": "babel-generator@>=6.9.0 <7.0.0" }, "babel-helper-builder-react-jsx": { @@ -216,8 +216,8 @@ "from": "babel-plugin-transform-es2015-typeof-symbol@>=6.8.0 <7.0.0" }, "babel-plugin-transform-es2015-unicode-regex": { - "version": "6.8.0", - "resolved": "https://registry.npmjs.org/babel-plugin-transform-es2015-unicode-regex/-/babel-plugin-transform-es2015-unicode-regex-6.8.0.tgz", + "version": "6.11.0", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-es2015-unicode-regex/-/babel-plugin-transform-es2015-unicode-regex-6.11.0.tgz", "from": "babel-plugin-transform-es2015-unicode-regex@>=6.8.0 <7.0.0" }, "babel-plugin-transform-es3-member-expression-literals": { @@ -271,9 +271,9 @@ "from": "babel-plugin-transform-strict-mode@>=6.8.0 <7.0.0" }, "babel-preset-meteor": { - "version": "6.11.0", - "resolved": "https://registry.npmjs.org/babel-preset-meteor/-/babel-preset-meteor-6.11.0.tgz", - "from": "babel-preset-meteor@>=6.11.0 <6.12.0" + "version": "6.11.1", + "resolved": "https://registry.npmjs.org/babel-preset-meteor/-/babel-preset-meteor-6.11.1.tgz", + "from": "babel-preset-meteor@6.11.1" }, "babel-preset-react": { "version": "6.5.0", @@ -308,7 +308,7 @@ "babylon": { "version": "6.8.1", "resolved": "https://registry.npmjs.org/babylon/-/babylon-6.8.1.tgz", - "from": "babylon@>=6.8.1 <6.9.0" + "from": "babylon@6.8.1" }, "balanced-match": { "version": "0.4.1", @@ -391,9 +391,9 @@ "from": "is-finite@>=1.0.0 <2.0.0" }, "js-tokens": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-1.0.3.tgz", - "from": "js-tokens@>=1.0.2 <2.0.0" + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-2.0.0.tgz", + "from": "js-tokens@>=2.0.0 <3.0.0" }, "jsesc": { "version": "0.5.0", @@ -413,17 +413,24 @@ "loose-envify": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.2.0.tgz", - "from": "loose-envify@>=1.0.0 <2.0.0" + "from": "loose-envify@>=1.0.0 <2.0.0", + "dependencies": { + "js-tokens": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-1.0.3.tgz", + "from": "js-tokens@>=1.0.1 <2.0.0" + } + } }, "magic-string": { - "version": "0.15.1", - "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.15.1.tgz", + "version": "0.15.2", + "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.15.2.tgz", "from": "magic-string@>=0.15.0 <0.16.0" }, "meteor-babel": { - "version": "0.11.6", - "resolved": "https://registry.npmjs.org/meteor-babel/-/meteor-babel-0.11.6.tgz", - "from": "meteor-babel@0.11.6" + "version": "0.11.7", + "resolved": "https://registry.npmjs.org/meteor-babel/-/meteor-babel-0.11.7.tgz", + "from": "meteor-babel@0.11.7" }, "meteor-babel-helpers": { "version": "0.0.3", @@ -493,9 +500,9 @@ "from": "regenerator-runtime@>=0.9.5 <0.10.0" }, "regexpu-core": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/regexpu-core/-/regexpu-core-1.0.0.tgz", - "from": "regexpu-core@>=1.0.0 <2.0.0" + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/regexpu-core/-/regexpu-core-2.0.0.tgz", + "from": "regexpu-core@>=2.0.0 <3.0.0" }, "regjsgen": { "version": "0.2.0", @@ -508,9 +515,9 @@ "from": "regjsparser@>=0.1.4 <0.2.0" }, "reify": { - "version": "0.3.4", - "resolved": "https://registry.npmjs.org/reify/-/reify-0.3.4.tgz", - "from": "reify@>=0.3.4 <0.4.0" + "version": "0.3.6", + "resolved": "https://registry.npmjs.org/reify/-/reify-0.3.6.tgz", + "from": "reify@>=0.3.6 <0.4.0" }, "repeating": { "version": "1.1.3", diff --git a/packages/babel-compiler/package.js b/packages/babel-compiler/package.js index c40bcb4ee0..81bcc56149 100644 --- a/packages/babel-compiler/package.js +++ b/packages/babel-compiler/package.js @@ -6,11 +6,11 @@ Package.describe({ // isn't possible because you can't publish a non-recommended // release with package versions that don't have a pre-release // identifier at the end (eg, -dev) - version: '6.8.3' + version: '6.8.4' }); Npm.depends({ - 'meteor-babel': '0.11.6', + 'meteor-babel': '0.11.7', }); Package.onUse(function (api) { diff --git a/packages/caching-compiler/package.js b/packages/caching-compiler/package.js index 92240494ee..10cbd84dbe 100644 --- a/packages/caching-compiler/package.js +++ b/packages/caching-compiler/package.js @@ -1,6 +1,6 @@ Package.describe({ name: 'caching-compiler', - version: '1.0.5_1', + version: '1.0.6', summary: 'An easy way to make compiler plugins cache', documentation: 'README.md' }); diff --git a/packages/coffeescript/package.js b/packages/coffeescript/package.js index a6112a6d46..4e31ee7a2f 100644 --- a/packages/coffeescript/package.js +++ b/packages/coffeescript/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "Javascript dialect with fewer braces and semicolons", - version: "1.1.2_1" + version: "1.1.3" }); Package.registerBuildPlugin({ diff --git a/packages/ddp-client/package.js b/packages/ddp-client/package.js index 91c48045b3..42f7db47a7 100644 --- a/packages/ddp-client/package.js +++ b/packages/ddp-client/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "Meteor's latency-compensated distributed data client", - version: '1.2.8_1', + version: '1.2.9', documentation: null }); diff --git a/packages/ddp-server/package.js b/packages/ddp-server/package.js index 433ead690f..1f752ca6a7 100644 --- a/packages/ddp-server/package.js +++ b/packages/ddp-server/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "Meteor's latency-compensated distributed data server", - version: '1.2.8_1', + version: '1.2.9', documentation: null }); diff --git a/packages/ecmascript-runtime/package.js b/packages/ecmascript-runtime/package.js index 94724afa6e..c56f531e2f 100644 --- a/packages/ecmascript-runtime/package.js +++ b/packages/ecmascript-runtime/package.js @@ -1,6 +1,6 @@ Package.describe({ name: "ecmascript-runtime", - version: "0.2.11_1", + version: "0.2.12", summary: "Polyfills for new ECMAScript 2015 APIs like Map and Set", git: "https://github.com/meteor/ecmascript-runtime", documentation: "README.md" diff --git a/packages/ecmascript/package.js b/packages/ecmascript/package.js index 6a23de12a7..e2ab391925 100644 --- a/packages/ecmascript/package.js +++ b/packages/ecmascript/package.js @@ -1,6 +1,6 @@ Package.describe({ name: 'ecmascript', - version: '0.4.6_1', + version: '0.4.7', summary: 'Compiler plugin that supports ES2015+ in all .js files', documentation: 'README.md' }); diff --git a/packages/email/package.js b/packages/email/package.js index 09d05445ca..cfd71c0643 100644 --- a/packages/email/package.js +++ b/packages/email/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "Send email messages", - version: "1.0.14_1" + version: "1.0.15" }); Npm.depends({ diff --git a/packages/es5-shim/package.js b/packages/es5-shim/package.js index d864fa2ca9..fe81b86495 100644 --- a/packages/es5-shim/package.js +++ b/packages/es5-shim/package.js @@ -1,6 +1,6 @@ Package.describe({ name: "es5-shim", - version: "4.5.12_1", + version: "4.5.13", summary: "Shims and polyfills to improve ECMAScript 5 support", documentation: "README.md" }); diff --git a/packages/http/package.js b/packages/http/package.js index 825793ef26..204bea1a66 100644 --- a/packages/http/package.js +++ b/packages/http/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "Make HTTP calls to remote servers", - version: '1.1.7' + version: '1.1.8' }); Npm.depends({ diff --git a/packages/jshint/package.js b/packages/jshint/package.js index 6409f12e66..22dff3944c 100644 --- a/packages/jshint/package.js +++ b/packages/jshint/package.js @@ -1,6 +1,6 @@ Package.describe({ name: 'jshint', - version: '1.0.4_1', + version: '1.0.5', summary: 'Lint all your JavaScript files with JSHint.', documentation: 'README.md' }); diff --git a/packages/less/package.js b/packages/less/package.js index 5e5cc5a476..e7abb57668 100644 --- a/packages/less/package.js +++ b/packages/less/package.js @@ -1,6 +1,6 @@ Package.describe({ name: 'less', - version: '2.6.3_1', + version: '2.6.4', summary: 'Leaner CSS language', documentation: 'README.md' }); diff --git a/packages/logging/package.js b/packages/logging/package.js index 45bb224d4b..473194385b 100644 --- a/packages/logging/package.js +++ b/packages/logging/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "Logging facility.", - version: '1.0.13_1' + version: '1.0.14' }); Npm.depends({ diff --git a/packages/meteor-tool/package.js b/packages/meteor-tool/package.js index 93093b54c6..7d4915f0e4 100644 --- a/packages/meteor-tool/package.js +++ b/packages/meteor-tool/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "The Meteor command-line tool", - version: '1.3.4_1' + version: '1.3.4_2' }); Package.includeTool(); diff --git a/packages/meteor/package.js b/packages/meteor/package.js index 5b1b1d8bd9..57e2871a17 100644 --- a/packages/meteor/package.js +++ b/packages/meteor/package.js @@ -2,7 +2,7 @@ Package.describe({ summary: "Core Meteor environment", - version: '1.1.15_1' + version: '1.1.16' }); Package.registerBuildPlugin({ diff --git a/packages/minifier-css/package.js b/packages/minifier-css/package.js index aaf9d3ed27..7163d04566 100644 --- a/packages/minifier-css/package.js +++ b/packages/minifier-css/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "CSS minifier", - version: "1.1.12_1" + version: "1.1.13" }); Npm.depends({ diff --git a/packages/minifier-js/package.js b/packages/minifier-js/package.js index 5bb8902e4a..7938b2096d 100644 --- a/packages/minifier-js/package.js +++ b/packages/minifier-js/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "JavaScript minifier", - version: "1.1.12_1" + version: "1.1.13" }); Npm.depends({ diff --git a/packages/modules-runtime/package.js b/packages/modules-runtime/package.js index e2651c7211..d12e368a80 100644 --- a/packages/modules-runtime/package.js +++ b/packages/modules-runtime/package.js @@ -1,6 +1,6 @@ Package.describe({ name: "modules-runtime", - version: "0.6.4_1", + version: "0.6.5", summary: "CommonJS module system", git: "https://github.com/benjamn/install", documentation: "README.md" diff --git a/packages/modules/.npm/package/npm-shrinkwrap.json b/packages/modules/.npm/package/npm-shrinkwrap.json index 8ae0614a2f..c13812da88 100644 --- a/packages/modules/.npm/package/npm-shrinkwrap.json +++ b/packages/modules/.npm/package/npm-shrinkwrap.json @@ -6,19 +6,19 @@ "from": "acorn@>=3.2.0 <3.3.0" }, "ast-types": { - "version": "0.8.16", - "resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.8.16.tgz", + "version": "0.8.17", + "resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.8.17.tgz", "from": "ast-types@>=0.8.16 <0.9.0" }, "magic-string": { - "version": "0.15.1", - "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.15.1.tgz", + "version": "0.15.2", + "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.15.2.tgz", "from": "magic-string@>=0.15.0 <0.16.0" }, "reify": { - "version": "0.3.4", - "resolved": "https://registry.npmjs.org/reify/-/reify-0.3.4.tgz", - "from": "reify@0.3.4" + "version": "0.3.6", + "resolved": "https://registry.npmjs.org/reify/-/reify-0.3.6.tgz", + "from": "reify@0.3.6" }, "vlq": { "version": "0.2.1", diff --git a/packages/modules/package.js b/packages/modules/package.js index f445ac250c..c24ecdfb64 100644 --- a/packages/modules/package.js +++ b/packages/modules/package.js @@ -1,12 +1,12 @@ Package.describe({ name: "modules", - version: "0.6.4", + version: "0.6.5", summary: "CommonJS module system", documentation: "README.md" }); Npm.depends({ - reify: "0.3.4" + reify: "0.3.6" }); Package.onUse(function(api) { diff --git a/packages/npm-mongo/package.js b/packages/npm-mongo/package.js index 0ec82ab8d8..559ab34995 100644 --- a/packages/npm-mongo/package.js +++ b/packages/npm-mongo/package.js @@ -3,7 +3,7 @@ Package.describe({ summary: "Wrapper around the mongo npm package", - version: '1.4.44_1', + version: '1.4.45', documentation: null }); diff --git a/packages/promise/.npm/package/npm-shrinkwrap.json b/packages/promise/.npm/package/npm-shrinkwrap.json index d45400431b..b65eb73c37 100644 --- a/packages/promise/.npm/package/npm-shrinkwrap.json +++ b/packages/promise/.npm/package/npm-shrinkwrap.json @@ -2,6 +2,7 @@ "dependencies": { "meteor-promise": { "version": "0.7.2", + "resolved": "https://registry.npmjs.org/meteor-promise/-/meteor-promise-0.7.2.tgz", "from": "meteor-promise@0.7.2" }, "promise": { diff --git a/packages/promise/package.js b/packages/promise/package.js index 189d24f428..393536ed51 100644 --- a/packages/promise/package.js +++ b/packages/promise/package.js @@ -1,6 +1,6 @@ Package.describe({ name: "promise", - version: "0.7.2_1", + version: "0.7.3", summary: "ECMAScript 2015 Promise polyfill with Fiber support", git: "https://github.com/meteor/promise", documentation: "README.md" diff --git a/packages/standard-minifier-css/package.js b/packages/standard-minifier-css/package.js index 5600f5fb95..3114cfa5e1 100644 --- a/packages/standard-minifier-css/package.js +++ b/packages/standard-minifier-css/package.js @@ -1,6 +1,6 @@ Package.describe({ name: 'standard-minifier-css', - version: '1.0.7_1', + version: '1.0.8', summary: 'Standard css minifier used with Meteor apps by default.', documentation: 'README.md' }); diff --git a/packages/standard-minifier-js/package.js b/packages/standard-minifier-js/package.js index d10d2a480b..fc610cd720 100644 --- a/packages/standard-minifier-js/package.js +++ b/packages/standard-minifier-js/package.js @@ -1,6 +1,6 @@ Package.describe({ name: 'standard-minifier-js', - version: '1.0.7_1', + version: '1.0.8', summary: 'Standard javascript minifiers used with Meteor apps by default.', documentation: 'README.md' }); diff --git a/packages/static-html/package.js b/packages/static-html/package.js index c09b5d2489..fd3882b337 100644 --- a/packages/static-html/package.js +++ b/packages/static-html/package.js @@ -1,5 +1,5 @@ Package.describe({ - version: '1.0.10_1', + version: '1.0.11', // Brief, one-line summary of the package. summary: 'Define static page content in .html files', git: 'https://github.com/meteor/meteor', diff --git a/packages/stylus/package.js b/packages/stylus/package.js index 6d5a7f2275..fd9cd284f9 100644 --- a/packages/stylus/package.js +++ b/packages/stylus/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: 'Expressive, dynamic, robust CSS', - version: "2.512.3_1" + version: "2.512.4" }); Package.registerBuildPlugin({ diff --git a/packages/templating/package.js b/packages/templating/package.js index 16e65aa0ee..7a275c607f 100644 --- a/packages/templating/package.js +++ b/packages/templating/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "Allows templates to be defined in .html files", - version: '1.1.12_1' + version: '1.1.13' }); // Today, this package is closely intertwined with Handlebars, meaning diff --git a/packages/webapp/package.js b/packages/webapp/package.js index b30bf0fbfc..b8dc9c9fdc 100644 --- a/packages/webapp/package.js +++ b/packages/webapp/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "Serves a Meteor app over HTTP", - version: '1.2.9_1' + version: '1.2.10' }); Npm.depends({connect: "2.30.2", diff --git a/packages/xmlbuilder/package.js b/packages/xmlbuilder/package.js index 500938e317..36bcd5edb7 100644 --- a/packages/xmlbuilder/package.js +++ b/packages/xmlbuilder/package.js @@ -1,6 +1,6 @@ Package.describe({ summary: "An XML builder for node.js similar to java-xmlbuilder.", - version: '2.4.12_1' + version: '2.4.13' }); Npm.depends({ diff --git a/scripts/admin/meteor-release-experimental.json b/scripts/admin/meteor-release-experimental.json index c98c9733a2..d8a332b8dd 100644 --- a/scripts/admin/meteor-release-experimental.json +++ b/scripts/admin/meteor-release-experimental.json @@ -1,6 +1,6 @@ { "track": "METEOR", - "version": "1.3.4.1-rc.0", + "version": "1.3.4.2-rc.1", "recommended": false, "official": false, "description": "Meteor" diff --git a/scripts/admin/meteor-release-official.json b/scripts/admin/meteor-release-official.json index eff1bd2584..ee4929144f 100644 --- a/scripts/admin/meteor-release-official.json +++ b/scripts/admin/meteor-release-official.json @@ -1,6 +1,6 @@ { "track": "METEOR", - "version": "1.3.4.1", + "version": "1.3.4.2", "recommended": false, "official": true, "description": "The Official Meteor Distribution" diff --git a/scripts/dev-bundle-tool-package.js b/scripts/dev-bundle-tool-package.js index 9886ecbbbe..94f6509c04 100644 --- a/scripts/dev-bundle-tool-package.js +++ b/scripts/dev-bundle-tool-package.js @@ -14,7 +14,7 @@ var packageJson = { npm: "3.9.6", "node-gyp": "3.3.1", "node-pre-gyp": "0.6.26", - "meteor-babel": "0.11.6", + "meteor-babel": "0.11.7", "meteor-promise": "0.7.2", fibers: "1.0.13", promise: "7.1.1", diff --git a/tools/cli/commands-packages.js b/tools/cli/commands-packages.js index b1aa082b42..c0dcfabd53 100644 --- a/tools/cli/commands-packages.js +++ b/tools/cli/commands-packages.js @@ -1533,8 +1533,9 @@ var maybeUpdateRelease = function (options) { main.captureAndExit("=> Errors while initializing project:", function () { projectContext.prepareProjectForBuild(); }); - // Write the new release to .meteor/release. - projectContext.releaseFile.write(solutionReleaseName); + + projectContext.writeReleaseFileAndDevBundleLink(solutionReleaseName); + projectContext.packageMapDelta.displayOnConsole({ title: ("Changes to your project's package version selections from " + "updating the release:") diff --git a/tools/cli/commands.js b/tools/cli/commands.js index 55af0cd049..dbad70cca2 100644 --- a/tools/cli/commands.js +++ b/tools/cli/commands.js @@ -1611,23 +1611,30 @@ function doTestCommand(options) { projectContextOptions.projectLocalDir = files.pathJoin(testRunnerAppDir, '.meteor', 'local'); // Copy the existing build and isopacks to speed up the initial start - const copyDirIntoTestRunnerApp = (...parts) => { + function copyDirIntoTestRunnerApp(allowSymlink, ...parts) { // Depending on whether the user has run `meteor run` or other commands, they // may or may not exist yet const appDirPath = files.pathJoin(options.appDir, ...parts); - if (files.exists(appDirPath)) { - files.cp_r( - appDirPath, - files.pathJoin(testRunnerAppDir, ...parts), - {preserveSymlinks: true} - ); + const testDirPath = files.pathJoin(testRunnerAppDir, ...parts); + + files.mkdir_p(appDirPath); + files.mkdir_p(files.pathDirname(testDirPath)); + + if (allowSymlink) { + // Windows can create junction links without administrator + // privileges since both paths refer to directories. + files.symlink(appDirPath, testDirPath, "junction"); + } else { + files.cp_r(appDirPath, testDirPath, { + preserveSymlinks: true + }); } } - copyDirIntoTestRunnerApp('.meteor', 'local', 'build'); - copyDirIntoTestRunnerApp('.meteor', 'local', 'bundler-cache'); - copyDirIntoTestRunnerApp('.meteor', 'local', 'isopacks'); - copyDirIntoTestRunnerApp('.meteor', 'local', 'plugin-cache'); + copyDirIntoTestRunnerApp(false, '.meteor', 'local', 'build'); + copyDirIntoTestRunnerApp(true, '.meteor', 'local', 'bundler-cache'); + copyDirIntoTestRunnerApp(true, '.meteor', 'local', 'isopacks'); + copyDirIntoTestRunnerApp(true, '.meteor', 'local', 'plugin-cache'); projectContext = new projectContextModule.ProjectContext(projectContextOptions); diff --git a/tools/cli/dev-bundle-bin-commands.js b/tools/cli/dev-bundle-bin-commands.js index f8316377a2..19bf936d55 100644 --- a/tools/cli/dev-bundle-bin-commands.js +++ b/tools/cli/dev-bundle-bin-commands.js @@ -10,25 +10,38 @@ var win32Extensions = { // command, as in `meteor npm` or `meteor node`, because we don't want to // require("./main.js") for these commands. var devBundleBinCommand = process.argv[2]; +var args = process.argv.slice(3); + +function getChildProcess() { + if (! win32Extensions.hasOwnProperty(devBundleBinCommand)) { + return Promise.resolve(null); + } -if (win32Extensions.hasOwnProperty(devBundleBinCommand)) { var helpers = require("./dev-bundle-bin-helpers.js"); if (process.platform === "win32") { devBundleBinCommand += win32Extensions[devBundleBinCommand]; } - var cmd = helpers.getCommandPath(devBundleBinCommand); - var args = process.argv.slice(3); + return Promise.all([ + helpers.getCommandPath(devBundleBinCommand), + helpers.getEnv() + ]).then(function (cmdAndEnv) { + var cmd = cmdAndEnv[0]; + var env = cmdAndEnv[1]; + var child = require("child_process").spawn(cmd, args, { + stdio: "inherit", + env: env + }); - exports.process = require("child_process").spawn(cmd, args, { - stdio: "inherit", - env: helpers.getEnv() - }); + require("./flush-buffers-on-exit-in-windows.js"); - require("./flush-buffers-on-exit-in-windows.js"); + child.on("exit", function (exitCode) { + process.exit(exitCode); + }); - exports.process.on("exit", function (exitCode) { - process.exit(exitCode); + return child; }); } + +module.exports = getChildProcess(); diff --git a/tools/cli/dev-bundle-bin-helpers.js b/tools/cli/dev-bundle-bin-helpers.js index ee9f49c85f..11b55ae849 100644 --- a/tools/cli/dev-bundle-bin-helpers.js +++ b/tools/cli/dev-bundle-bin-helpers.js @@ -1,43 +1,54 @@ +var fs = require("fs"); var path = require("path"); -var devBundleDir = path.resolve(__dirname, "..", "..", "dev_bundle"); -var binDir = path.join(devBundleDir, "bin"); +var devBundlePromise = require("./dev-bundle.js"); +var Promise = devBundlePromise.constructor; +var binDirPromise = devBundlePromise.then(function (devBundleDir) { + return path.join(devBundleDir, "bin"); +}); exports.getCommandPath = function (command) { - return path.join(binDir, command); + return binDirPromise.then(function (binDir) { + return path.join(binDir, command); + }); }; -exports.getEnv = function () { - var env = Object.create(process.env); - var paths = [ +exports.getEnv = function() { + return Promise.all([ // When npm looks for node, it must find dev_bundle/bin/node. - binDir, + binDirPromise, + devBundlePromise + ]).then(function (paths) { + var devBundleDir = paths[1]; + // Also make available any scripts installed by packages in // dev_bundle/lib/node_modules, such as node-gyp. - path.join(devBundleDir, "lib", "node_modules", ".bin"), - ]; + paths[1] = path.join(devBundleDir, "lib", "node_modules", ".bin"); - var PATH = env.PATH || env.Path; - if (PATH) { - paths.push(PATH); - } + var env = Object.create(process.env); - env.PATH = paths.join(path.delimiter); + var PATH = env.PATH || env.Path; + if (PATH) { + paths.push(PATH); + } - if (process.platform === "win32") { - // On Windows we provide a reliable version of python.exe for use by - // node-gyp (the tool that rebuilds binary node modules). #WinPy - env.PYTHON = env.PYTHON || path.join( - devBundleDir, "python", "python.exe"); + env.PATH = paths.join(path.delimiter); - // We don't try to install a compiler toolchain on the developer's - // behalf, but setting GYP_MSVS_VERSION helps select the right one. - env.GYP_MSVS_VERSION = env.GYP_MSVS_VERSION || "2015"; + if (process.platform === "win32") { + // On Windows we provide a reliable version of python.exe for use by + // node-gyp (the tool that rebuilds binary node modules). #WinPy + env.PYTHON = env.PYTHON || path.join( + devBundleDir, "python", "python.exe"); - // While the original process.env object allows for case insensitive - // access on Windows, Object.create interferes with that behavior, so - // here we ensure env.PATH === env.Path on Windows. - env.Path = env.PATH; - } + // We don't try to install a compiler toolchain on the developer's + // behalf, but setting GYP_MSVS_VERSION helps select the right one. + env.GYP_MSVS_VERSION = env.GYP_MSVS_VERSION || "2015"; - return env; + // While the original process.env object allows for case insensitive + // access on Windows, Object.create interferes with that behavior, + // so here we ensure env.PATH === env.Path on Windows. + env.Path = env.PATH; + } + + return env; + }); }; diff --git a/tools/cli/dev-bundle.js b/tools/cli/dev-bundle.js new file mode 100644 index 0000000000..da6a06491f --- /dev/null +++ b/tools/cli/dev-bundle.js @@ -0,0 +1,194 @@ +// Note that this file is required before we install our Babel hooks in +// ../tool-env/install-babel.js, so we can't use ES2015+ syntax here. + +// This file replicates some functionality from elsewhere in tools code, +// but that's unavoidable if we don't want to install Babel and load all +// the rest of the code every time we run `meteor npm` or `meteor node`. + +var fs = require("fs"); +var path = require("path"); +var rootDir = path.resolve(__dirname, "..", ".."); +var defaultDevBundlePromise = + Promise.resolve(path.join(rootDir, "dev_bundle")); + +function getDevBundleDir() { + // Note that this code does not care if we are running meteor from a + // checkout, because it's always better to respect the .meteor/release + // file of the current app, if possible. + + var releaseFile = find( + process.cwd(), + makeStatTest("isFile"), + ".meteor", "release" + ); + + if (! releaseFile) { + return defaultDevBundlePromise; + } + + var devBundleLink = path.join( + path.dirname(releaseFile), + "dev_bundle" + ); + + var devBundleStat = statOrNull(devBundleLink, "isDirectory"); + if (devBundleStat) { + return new Promise(function (resolve) { + resolve(fs.realpathSync(devBundleLink)); + }); + } + + var release = fs.readFileSync( + releaseFile, "utf8" + ).replace(/^\s+|\s+$/g, ""); + + if (! /^METEOR@\d+/.test(release)) { + return defaultDevBundlePromise; + } + + return getDevBundleForRelease(release).then(function (devBundleDir) { + if (devBundleDir) { + fs.symlink(devBundleDir, devBundleLink, "junction"); + return devBundleDir; + } + + return defaultDevBundlePromise; + }); +} + +function getDevBundleForRelease(release) { + var parts = release.split("@"); + if (parts.length < 2) { + return null; + } + + var track = parts[0]; + var version = parts.slice(1).join("@"); + + var packageMetadataDir = find( + rootDir, + makeStatTest("isDirectory"), + ".meteor", "package-metadata" + ); + + if (! packageMetadataDir) { + return null; + } + + var meteorToolDir = path.resolve( + packageMetadataDir, + "..", "packages", "meteor-tool" + ); + + var meteorToolStat = statOrNull(meteorToolDir, "isDirectory"); + if (! meteorToolStat) { + return null; + } + + var dbPath = path.join( + packageMetadataDir, + "v2.0.1", + "packages.data.db" + ); + + var dbStat = statOrNull(dbPath, "isFile"); + if (! dbStat) { + return null; + } + + var sqlite3 = require("sqlite3"); + var db = new sqlite3.Database(dbPath); + + return new Promise(function (resolve, reject) { + db.get( + "SELECT content FROM releaseVersions WHERE track=? AND version=?", + [track, version], + function (error, data) { + if (error) { + reject(error); + } else { + var tool = JSON.parse(data.content).tool; + var devBundleDir = path.join( + meteorToolDir, + tool.split("@").slice(1).join("@"), + "mt-" + getHostArch(), + "dev_bundle" + ); + + var devBundleStat = statOrNull(devBundleDir, "isDirectory"); + if (devBundleStat) { + resolve(devBundleDir); + } else { + resolve(null); + } + } + } + ); + }); +} + +function statOrNull(path, statMethod) { + try { + var stat = fs.statSync(path); + } catch (e) { + if (e.code !== "ENOENT") { + throw e; + } + } + + if (stat) { + if (typeof statMethod === "string") { + if (stat[statMethod]()) { + return stat; + } + } else { + return stat; + } + } + + return null; +} + +function find(dir, predicate) { + var joinArgs = Array.prototype.slice.call(arguments, 2); + joinArgs.unshift(null); + + while (true) { + joinArgs[0] = dir; + var joined = path.join.apply(path, joinArgs); + if (predicate(joined)) { + return joined; + } + + var parentDir = path.dirname(dir); + if (parentDir === dir) break; + dir = parentDir; + } + + return null; +} + +function makeStatTest(method) { + return function (file) { + return statOrNull(file, method); + }; +} + +function getHostArch() { + if (process.platform === "win32") { + return "os.windows.x86_32"; + } + + if (process.platform === "linux") { + if (process.arch === "x64") { + return "os.linux.x86_64"; + } + return "os.linux.x86_32"; + } + + if (process.platform === "darwin") { + return "os.osx.x86_64"; + } +} + +module.exports = getDevBundleDir(); diff --git a/tools/index.js b/tools/index.js index f582834589..6522c41c3d 100644 --- a/tools/index.js +++ b/tools/index.js @@ -1,4 +1,20 @@ -if (! require('./cli/dev-bundle-bin-commands.js').process) { +require("./tool-env/install-promise.js"); + +require("./cli/dev-bundle-bin-commands.js").then(function (child) { + if (! child) { + // Use process.nextTick here to prevent the Promise from swallowing + // errors from the rest of the setup code. + process.nextTick(continueSetup); + } + // If we spawned a process to handle a dev_bundle/bin command like + // `meteor npm` or `meteor node`, then don't run any other tool code. +}, function (error) { + process.nextTick(function () { + throw error; + }); +}); + +function continueSetup() { // Set up the Babel transpiler require('./tool-env/install-babel.js'); diff --git a/tools/isobuild/bundler.js b/tools/isobuild/bundler.js index c67725b690..c13ad758a1 100644 --- a/tools/isobuild/bundler.js +++ b/tools/isobuild/bundler.js @@ -157,6 +157,7 @@ var compiler = require('./compiler.js'); var PackageSource = require('./package-source.js'); import Builder from './builder.js'; var compilerPluginModule = require('./compiler-plugin.js'); +import { JsFile, CssFile } from './minifier-plugin.js'; var meteorNpm = require('./meteor-npm.js'); var files = require('../fs/files.js'); @@ -1057,11 +1058,8 @@ class Target { // Minify the JS in this target minifyJs(minifierDef, minifyMode) { - // Avoid circular deps from top-level import. - const minifierPluginModule = require('./minifier-plugin.js'); - const sources = _.map(this.js, function (file) { - return new minifierPluginModule.JsFile(file, { + return new JsFile(file, { arch: this.arch }); }); @@ -1235,11 +1233,8 @@ class ClientTarget extends Target { // Minify the CSS in this target minifyCss(minifierDef, minifyMode) { - // Avoid circular deps from top-level import. - const minifierPluginModule = require('./minifier-plugin.js'); - const sources = this.css.map((file) => { - return new minifierPluginModule.CssFile(file, { + return new CssFile(file, { arch: this.arch }); }); @@ -1890,8 +1885,7 @@ class JsImage { }; if (nmd.local) { - var prodPackageNames = - meteorNpm.getProdPackageNames(nmd.sourcePath); + let prodPackageNames; // When copying a local node_modules directory, ignore any npm // package directories not in the list of production package @@ -1906,8 +1900,15 @@ class JsImage { copyOptions.directoryFilter = function (dir) { var base = files.pathBasename(dir); var parentBase = files.pathBasename(files.pathDirname(dir)); - return parentBase !== "node_modules" || - _.has(prodPackageNames, base); + if (parentBase !== "node_modules") { + return true; + } + + // Compute prodPackageNames lazily. + prodPackageNames = prodPackageNames || + meteorNpm.getProdPackageNames(nmd.sourcePath); + + return _.has(prodPackageNames, base); }; } diff --git a/tools/isobuild/compiler-plugin.js b/tools/isobuild/compiler-plugin.js index 28b7a5c1f6..e17912a591 100644 --- a/tools/isobuild/compiler-plugin.js +++ b/tools/isobuild/compiler-plugin.js @@ -59,7 +59,7 @@ import { isTestFilePath } from './test-files.js'; // Cache the (slightly post-processed) results of linker.fullLink. const CACHE_SIZE = process.env.METEOR_LINKER_CACHE_SIZE || 1024*1024*100; const CACHE_DEBUG = !! process.env.METEOR_TEST_PRINT_LINKER_CACHE_DEBUG; -const LINKER_CACHE_SALT = 7; // Increment this number to force relinking. +const LINKER_CACHE_SALT = 8; // Increment this number to force relinking. const LINKER_CACHE = new LRU({ max: CACHE_SIZE, // Cache is measured in bytes. We don't care about servePath. diff --git a/tools/isobuild/meteor-npm.js b/tools/isobuild/meteor-npm.js index 71b429a310..19c1cc27a5 100644 --- a/tools/isobuild/meteor-npm.js +++ b/tools/isobuild/meteor-npm.js @@ -14,6 +14,7 @@ var buildmessage = require('../utils/buildmessage.js'); var utils = require('../utils/utils.js'); var runLog = require('../runners/run-log.js'); var Profile = require('../tool-env/profile.js').Profile; +import { execFileAsync } from "../utils/processes.js"; var meteorNpm = exports; @@ -161,7 +162,7 @@ Profile("meteorNpm.rebuildIfNonPortable", function (nodeModulesDir) { files.readdir(nodeModulesDir).forEach(function (pkg) { const pkgPath = files.pathJoin(nodeModulesDir, pkg); - if (isPortable(pkgPath, true)) { + if (isPortable(pkgPath)) { return; } @@ -239,33 +240,24 @@ Profile("meteorNpm.rebuildIfNonPortable", function (nodeModulesDir) { return true; }); -function isPortable(dir, shouldCache) { - if (! files.lstat(dir).isDirectory()) { - return true; +function isPortable(dir) { + const lstat = files.lstat(dir); + if (! lstat.isDirectory()) { + // Non-directory files are portable unless they end with .node. + return ! dir.endsWith(".node"); } - return files.readdir(dir).every(itemName => { - const item = files.pathJoin(dir, itemName); + const pkgJsonStat = files.statOrNull(files.pathJoin(dir, "package.json")); + const canCache = pkgJsonStat && pkgJsonStat.isFile(); + const portableFile = files.pathJoin(dir, ".meteor-portable"); - if (! files.lstat(item).isDirectory()) { - // Non-directory files are portable unless they end with .node. - return ! itemName.endsWith(".node"); - } - - if (! shouldCache) { - // Once we stop caching, we keep calling isPortable recursively - // without caching. - return isPortable(item); - } - - // Cache previous results by writing a boolean value to a hidden - // file called .meteor-portable. Although it's tempting to write - // this file once for the whole node_modules directory, it's - // important that we put separate files in the individual top-level - // package directories so that they will get cleared away the next - // time those packages are (re)installed. - - const portableFile = files.pathJoin(item, ".meteor-portable"); + if (canCache) { + // Cache previous results by writing a boolean value to a hidden file + // called .meteor-portable. Although it's tempting to write this file + // once for the whole node_modules directory, it's important that we + // put .meteor-portable files only in the individual top-level package + // directories, so that they will get cleared away the next time those + // packages are (re)installed. try { return JSON.parse(files.readFile(portableFile)); } catch (e) { @@ -274,20 +266,29 @@ function isPortable(dir, shouldCache) { throw e; } } + } else { + // Clean up any .meteor-portable files we mistakenly wrote in + // directories that do not contain package.json files. #7296 + fs.unlink(portableFile, error => {}); + } - const result = isPortable(item); + const result = files.readdir(dir).every( + // Ignore files that start with a ".", such as .bin directories. + itemName => itemName.startsWith(".") || + isPortable(files.pathJoin(dir, itemName))); + if (canCache) { // Write the .meteor-portable file asynchronously, and don't worry // if it fails, e.g. because the file system is read-only (#6591). // Failing to write the file only means more work next time. fs.writeFile( portableFile, JSON.stringify(result) + "\n", - (error) => {} + error => {}, ); + } - return result; - }); + return result; } // Return true if all of a package's npm dependencies are portable @@ -310,7 +311,7 @@ meteorNpm.dependenciesArePortable = function (nodeModulesDir) { // Only check/write .meteor-portable files in each of the top-level // package directories. - return isPortable(nodeModulesDir, true); + return isPortable(nodeModulesDir); }; var makeNewPackageNpmDir = function (newPackageNpmDir) { @@ -546,28 +547,34 @@ Profile("meteorNpm.runNpmCommand", function (args, cwd) { cwd = files.convertToOSPath(cwd); } - const env = require("../cli/dev-bundle-bin-helpers.js").getEnv(); + var getEnv = require("../cli/dev-bundle-bin-helpers.js").getEnv; - // Make sure we don't honor any user-provided configuration files. - env.npm_config_userconfig = npmUserConfigFile; + return getEnv().then(env => { + // Make sure we don't honor any user-provided configuration files. + env.npm_config_userconfig = npmUserConfigFile; - var opts = { cwd: cwd, env: env, maxBuffer: 10 * 1024 * 1024 }; + var opts = { + cwd: cwd, + env: env, + maxBuffer: 10 * 1024 * 1024 + }; - return new Promise(function (resolve) { - require('child_process').execFile( - npmPath, args, opts, function (err, stdout, stderr) { - if (meteorNpm._printNpmCalls) { - process.stdout.write(err ? 'failed\n' : 'done\n'); + return new Promise(function (resolve) { + require('child_process').execFile( + npmPath, args, opts, function (err, stdout, stderr) { + if (meteorNpm._printNpmCalls) { + process.stdout.write(err ? 'failed\n' : 'done\n'); + } + + resolve({ + success: ! err, + error: (err ? `${err.message}${stderr}` : stderr), + stdout: stdout, + stderr: stderr + }); } - - resolve({ - success: ! err, - error: (err ? `${err.message}${stderr}` : stderr), - stdout: stdout, - stderr: stderr - }); - } - ); + ); + }); }).await(); }); @@ -721,7 +728,7 @@ var installNpmModule = function (name, version, dir) { } const pkgDir = files.pathJoin(dir, "node_modules", name); - if (! isPortable(pkgDir, true)) { + if (! isPortable(pkgDir)) { recordLastRebuildVersions(pkgDir); } diff --git a/tools/project-context.js b/tools/project-context.js index 6b013c6c5c..ce9833f684 100644 --- a/tools/project-context.js +++ b/tools/project-context.js @@ -365,6 +365,38 @@ _.extend(ProjectContext.prototype, { self._completedStage = STAGE.READ_PROJECT_METADATA; }), + // Write the new release to .meteor/release and create a + // .meteor/dev_bundle symlink to the corresponding dev_bundle. + writeReleaseFileAndDevBundleLink(releaseName) { + assert.strictEqual(files.inCheckout(), false); + + this.releaseFile.write(releaseName); + + // Make a symlink from .meteor/dev_bundle to the actual dev_bundle. + const devBundleLink = files.pathJoin( + files.pathDirname(this.releaseFile.filename), + "dev_bundle" + ); + + if (files.exists(devBundleLink)) { + files.rm_recursive(devBundleLink); + } + + if (this.releaseFile.isCheckout()) { + // Only create the .meteor/dev_bundle symlink if it points to the + // dev_bundle of an actual release, but remove it first regardless. + return; + } + + files.symlink( + files.getDevBundle(), + devBundleLink, + // Since the target is a directory, Windows can create a junction + // without needing administrator privileges. + "junction" + ); + }, + _ensureProjectDir: function () { var self = this; files.mkdir_p(files.pathJoin(self.projectDir, '.meteor')); diff --git a/tools/runners/run-proxy.js b/tools/runners/run-proxy.js index 8b4075e5b2..1be4d33dd6 100644 --- a/tools/runners/run-proxy.js +++ b/tools/runners/run-proxy.js @@ -174,9 +174,11 @@ _.extend(Proxy.prototype, { try { return fn(); } catch (e) { - resOrSocket.writeHead(400, { - 'Content-Type': 'text/plain' - }); + if (typeof resOrSocket.writeHead === "function") { + resOrSocket.writeHead(400, { + 'Content-Type': 'text/plain' + }); + } resOrSocket.end("Bad request\n"); } } diff --git a/tools/shell-client.js b/tools/shell-client.js index e59ebc2a52..35071377b5 100644 --- a/tools/shell-client.js +++ b/tools/shell-client.js @@ -134,7 +134,7 @@ Cp.setUpSocket = function setUpSocket(sock, key) { sock.write(JSON.stringify({ terminal: ! process.env.EMACS, key: key - })); + }) + "\n"); process.stderr.write(shellBanner()); process.stdin.pipe(sock); diff --git a/tools/static-assets/server/mini-files.js b/tools/static-assets/server/mini-files.js index e76d4f9d65..8e75a6d59c 100644 --- a/tools/static-assets/server/mini-files.js +++ b/tools/static-assets/server/mini-files.js @@ -81,10 +81,16 @@ var wrapPathFunction = function (name, partialPaths) { // forget about conversion of absolute paths for Windows return toDosPath(p, partialPaths); }); - return toPosixPath(f.apply(path, args), partialPaths); - } else { - return f.apply(path, arguments); + + var result = f.apply(path, args); + if (typeof result === "string") { + result = toPosixPath(result, partialPaths); + } + + return result; } + + return f.apply(path, arguments); }; }; diff --git a/tools/static-assets/server/shell-server.js b/tools/static-assets/server/shell-server.js index ad5044ac19..3e93047ab2 100644 --- a/tools/static-assets/server/shell-server.js +++ b/tools/static-assets/server/shell-server.js @@ -161,6 +161,12 @@ Sp.onConnection = function onConnection(socket) { readJSONFromStream(socket, function (error, options, replInputSocket) { clearTimeout(timeout); + if (error) { + socket = null; + console.error(error.stack); + return; + } + if (options.key !== self.key) { if (socket) { socket.end(EXITING_MESSAGE + "\n"); diff --git a/tools/tool-env/install-promise.js b/tools/tool-env/install-promise.js new file mode 100644 index 0000000000..dc78ea6661 --- /dev/null +++ b/tools/tool-env/install-promise.js @@ -0,0 +1,10 @@ +// Install a global ES2015-compliant Promise constructor that knows how to +// run all its callbacks in Fibers. + +var Promise = global.Promise = global.Promise || + require("promise/lib/es6-extensions"); + +require("meteor-promise").makeCompatible( + Promise, + require("fibers") +); diff --git a/tools/tool-env/install-runtime.js b/tools/tool-env/install-runtime.js index aaa2a938d0..a134327915 100644 --- a/tools/tool-env/install-runtime.js +++ b/tools/tool-env/install-runtime.js @@ -1,12 +1,8 @@ // Install ES2015-complaint polyfills for Object, Array, String, Function, -// Symbol, Map, and Set, patching the native implementations if available. +// Symbol, Map, Set, and Promise, patching the native implementations when +// they are available. require("meteor-ecmascript-runtime"); - -// Install a global ES2015-compliant Promise constructor that knows how to -// run all its callbacks in Fibers. -var Promise = global.Promise = global.Promise || - require("promise/lib/es6-extensions"); -require("meteor-promise").makeCompatible(Promise, require("fibers")); +require("./install-promise.js"); // Verify that the babel-runtime package is available to be required. // The .join("/") prevents babel-plugin-transform-runtime from