Permalink
Browse files

"tools" -> "scripts", "engine" -> "tools"

  • Loading branch information...
1 parent fa0c307 commit 8a79edb43b2ba66a4f8e2764afcf5347ffdf092b @glasser glasser committed Mar 19, 2013
Showing with 157 additions and 158 deletions.
  1. +1 −1 .gitmodules
  2. +2 −2 meteor
  3. 0 {tools → scripts}/admin/bless-release.sh
  4. +4 −4 {tools → scripts}/admin/build-fake-release.sh
  5. 0 {tools → scripts}/admin/build-install-script.js
  6. +1 −1 {tools → scripts}/admin/build-package-tarballs.sh
  7. +5 −5 {tools → scripts}/admin/build-release.sh
  8. +40 −0 scripts/admin/build-tools-tarballs.sh
  9. +12 −12 tools/admin/build-engine-tree.sh → scripts/admin/build-tools-tree.sh
  10. 0 {tools → scripts}/admin/changelog.json
  11. 0 {tools → scripts}/admin/debian/changelog
  12. 0 {tools → scripts}/admin/debian/compat
  13. 0 {tools → scripts}/admin/debian/control
  14. 0 {tools → scripts}/admin/debian/copyright
  15. 0 {tools → scripts}/admin/debian/docs
  16. 0 {tools → scripts}/admin/debian/meteor.install
  17. 0 {tools → scripts}/admin/debian/rules
  18. 0 {tools → scripts}/admin/debian/source/format
  19. 0 {tools → scripts}/admin/deploy-examples.sh
  20. 0 {tools → scripts}/admin/find-new-npm-versions.sh
  21. +1 −1 {tools → scripts}/admin/initial-engine-post-upgrade.js
  22. +1 −0 scripts/admin/install-bootstrap.txt
  23. 0 {tools → scripts}/admin/install-template.sh
  24. 0 {tools → scripts}/admin/manifest.json
  25. +3 −3 {tools → scripts}/admin/meteor-bootstrap.sh
  26. 0 {tools → scripts}/admin/meteor.spec
  27. 0 {tools → scripts}/admin/publish-release.sh
  28. 0 {engine/skel → scripts/admin/publish-release}/.meteor/.gitignore
  29. 0 {tools → scripts}/admin/publish-release/.meteor/packages
  30. 0 {tools → scripts}/admin/publish-release/packages/awssum
  31. +10 −10 {tools → scripts}/admin/publish-release/server/publish-release.js
  32. 0 {tools → scripts}/admin/spark-standalone.sh
  33. +1 −1 {tools → scripts}/bundler-test.sh
  34. +2 −2 {tools → scripts}/cli-test.sh
  35. 0 {tools → scripts}/copy-release-from-jenkins.sh
  36. 0 {tools → scripts}/generate-dev-bundle.sh
  37. 0 {tools → scripts}/node.sh
  38. +4 −4 tools/run-engine-tests.sh → scripts/run-tools-tests.sh
  39. +0 −40 tools/admin/build-engine-tarballs.sh
  40. +0 −1 tools/admin/install-bootstrap.txt
  41. 0 {engine → tools}/app.html.in
  42. +2 −2 {engine → tools}/bundler.js
  43. 0 {engine → tools}/cleanup.js
  44. 0 {engine → tools}/deploy.js
  45. 0 {engine → tools}/fiber-helpers.js
  46. +8 −8 {engine → tools}/files.js
  47. +21 −21 {engine → tools}/meteor.js
  48. 0 {engine → tools}/meteor_npm.js
  49. 0 {engine → tools}/mongo_exit_codes.js
  50. 0 {engine → tools}/mongo_runner.js
  51. +1 −1 {engine → tools}/packages.js
  52. +1 −2 {engine → tools}/project.js
  53. +1 −1 {engine → tools}/run.js
  54. +1 −1 {engine → tools}/server/server.js
  55. 0 {engine/test-runner-app → tools/skel}/.meteor/.gitignore
  56. 0 {engine → tools}/skel/.meteor/packages
  57. 0 {engine → tools}/skel/~name~.css
  58. 0 {engine → tools}/skel/~name~.html
  59. 0 {engine → tools}/skel/~name~.js
  60. 0 {engine/tests/app-with-package → tools/test-runner-app}/.meteor/.gitignore
  61. 0 {engine → tools}/test-runner-app/.meteor/packages
  62. 0 {engine/tests/empty-app → tools/tests/app-with-package}/.meteor/.gitignore
  63. 0 {engine → tools}/tests/app-with-package/.meteor/packages
  64. 0 tools/{admin/publish-release → tests/empty-app}/.meteor/.gitignore
  65. 0 {engine → tools}/tests/empty-app/.meteor/packages
  66. 0 {engine → tools}/tests/test_bundler.js
  67. +1 −1 {engine → tools}/tests/test_bundler_npm.js
  68. 0 {engine → tools}/tests/test_bundler_options.js
  69. 0 {engine → tools}/updater.js
  70. +34 −34 {engine → tools}/warehouse.js
View
@@ -1,3 +1,3 @@
[submodule "meteor-awssum"]
- path = tools/admin/publish-release/packages/awssum
+ path = scripts/admin/publish-release/packages/awssum
url = https://github.com/avital/meteor-awssum
View
4 meteor
@@ -83,11 +83,11 @@ if [ -d "$SCRIPT_DIR/.git" ] || [ -f "$SCRIPT_DIR/.git" ]; then
fi
DEV_BUNDLE="$SCRIPT_DIR/dev_bundle"
- METEOR="$SCRIPT_DIR/engine/meteor.js"
+ METEOR="$SCRIPT_DIR/tools/meteor.js"
else
# In an install
DEV_BUNDLE=$(dirname "$SCRIPT_DIR")
- METEOR="$DEV_BUNDLE/engine/meteor.js"
+ METEOR="$DEV_BUNDLE/tools/meteor.js"
fi
File renamed without changes.
@@ -44,12 +44,12 @@ popd
# Copy post-upgrade script to where it is expected.
mkdir -p "$FAKE_TMPDIR/meteor/app/meteor"
-cp "$TOPDIR/tools/admin/initial-engine-post-upgrade.js" \
+cp "$TOPDIR/scripts/admin/initial-engine-post-upgrade.js" \
"$FAKE_TMPDIR/meteor/app/meteor/post-upgrade.js"
# Copy in meteor-bootstrap.sh, which will become the installed
# /usr/local/bin/meteor.
-cp "$TOPDIR/tools/admin/meteor-bootstrap.sh" \
+cp "$TOPDIR/scripts/admin/meteor-bootstrap.sh" \
"$FAKE_TMPDIR/meteor/app/meteor/meteor-bootstrap.sh"
OUTDIR="$TOPDIR/dist"
@@ -69,7 +69,7 @@ if [ "$UNAME" == "Linux" ] ; then
cp "$TARBALL" "meteor_${VERSION}.orig.tar.gz"
mkdir "meteor-${VERSION}"
cd "meteor-${VERSION}"
- cp -r "$TOPDIR/tools/admin/debian" .
+ cp -r "$TOPDIR/scripts/admin/debian" .
export TARBALL
dpkg-buildpackage
cp ../*.deb "$OUTDIR"
@@ -79,6 +79,6 @@ if [ "$UNAME" == "Linux" ] ; then
RPMDIR="$FAKE_TMPDIR/rpm"
mkdir $RPMDIR
rpmbuild -bb --define="TARBALL $TARBALL" \
- --define="_topdir $RPMDIR" "$TOPDIR/tools/admin/meteor.spec"
+ --define="_topdir $RPMDIR" "$TOPDIR/scripts/admin/meteor.spec"
cp $RPMDIR/RPMS/*/*.rpm "$OUTDIR"
fi
@@ -8,7 +8,7 @@
### At the moment smart packages don't support binary dependencies so
### we don't have to build on different architectures. At some point
### this will change, at which we'll use an approach similar to what
-### we do for engines.
+### we do for tools.
set -e
@@ -11,18 +11,18 @@ OUTDIR="$TOPDIR/dist"
rm -rf "$OUTDIR"
mkdir -p "$OUTDIR"
-tools/admin/build-engine-tarballs.sh
-ENGINE_VERSION=$(cat "$TOPDIR/.engine_version")
-tools/admin/build-package-tarballs.sh
+scripts/admin/build-tools-tarballs.sh
+TOOLS_VERSION=$(cat "$TOPDIR/.tools_version")
+scripts/admin/build-package-tarballs.sh
MANIFEST_PACKAGE_CHUNK=$(cat "$TOPDIR/.package_manifest_chunk")
# don't keep these around since they get outdated
-rm "$TOPDIR/.engine_version"
+rm "$TOPDIR/.tools_version"
rm "$TOPDIR/.package_manifest_chunk"
cat > "$OUTDIR/manifest.json" <<ENDOFMANIFEST
{
- "engine": "$ENGINE_VERSION",
+ "tools": "$TOOLS_VERSION",
"packages": {
$MANIFEST_PACKAGE_CHUNK
}
@@ -0,0 +1,40 @@
+#!/bin/bash
+
+set -e
+
+# cd to top level dir
+cd `dirname $0`
+cd ../..
+TOPDIR=$(pwd)
+
+UNAME=$(uname)
+ARCH=$(uname -m)
+
+TOOLS_TMPDIR=$(mktemp -d -t meteor-build-release-XXXXXXXX)
+trap 'rm -rf "$TOOLS_TMPDIR" >/dev/null 2>&1' 0
+
+# build the tools in a temporary directory. after its built we know
+# its version so rename the directory.
+mkdir -p "$TOOLS_TMPDIR/.meteor/tools"
+export TARGET_DIR="$TOOLS_TMPDIR/.meteor/tools/new"
+$TOPDIR/scripts/admin/build-tools-tree.sh
+TOOLS_VERSION=$(cat $TARGET_DIR/.tools_version.txt)
+mv "$TARGET_DIR" "$TOOLS_TMPDIR/.meteor/tools/$TOOLS_VERSION"
+
+ln -s "$TOOLS_VERSION" "$TOOLS_TMPDIR/.meteor/tools/latest"
+ln -s tools/latest/bin/meteor "$TOOLS_TMPDIR/.meteor/meteor"
+
+# tar it up
+OUTDIR="$TOPDIR/dist/tools"
+mkdir -p "$OUTDIR"
+
+TOOLS_TARBALL="$OUTDIR/meteor-tools-${TOOLS_VERSION}-${UNAME}-${ARCH}.tar.gz"
+echo "Tarring tools to: $TOOLS_TARBALL"
+tar -C "$TOOLS_TMPDIR/.meteor/tools" --exclude .meteor/local -czf "$TOOLS_TARBALL" "$TOOLS_VERSION"
+
+TOOLS_BOOTSTRAP_TARBALL="$OUTDIR/meteor-tools-bootstrap-${UNAME}-${ARCH}.tar.gz"
+echo "Tarring tools bootstrap to: $TOOLS_BOOTSTRAP_TARBALL"
+tar -C "$TOOLS_TMPDIR" --exclude .meteor/local -czf "$TOOLS_BOOTSTRAP_TARBALL" .meteor
+
+# A hacky (?) way to pass $TOOLS_VERSION back into build-release.sh
+echo $TOOLS_VERSION > $TOPDIR/.tools_version
@@ -1,9 +1,9 @@
#!/bin/bash
# This script fills TARGET_DIR with what should go into
-# /usr/local/meteor/engines/X.Y.Z
+# ~/.meteor/tools/VERSION
# It does not set up the top-level springboard file in
-# /usr/local/meteor/engines or the /usr/local/bin/meteor symlink.
+# ~/.meteor/tools or the ~/.meteor/meteor symlink.
cd `dirname $0`/../..
@@ -19,7 +19,7 @@ if [ -e "$TARGET_DIR" ] ; then
exit 1
fi
-echo "Setting up engine tree in $TARGET_DIR"
+echo "Setting up tools tree in $TARGET_DIR"
# make sure dev bundle exists before trying to install
./meteor --version || exit 1
@@ -28,28 +28,28 @@ function CPR {
tar -c --exclude .meteor/local "$1" | tar -x -C "$2"
}
-# The engine starts as a copy of the dev bundle.
+# The tools starts as a copy of the dev bundle.
cp -a dev_bundle "$TARGET_DIR"
# Copy over files and directories that we want in the tarball. Keep this list
-# synchronized with the files used in the $ENGINE_VERSION calculation below. The
+# synchronized with the files used in the $TOOLS_VERSION calculation below. The
# "meteor" script file contains the version number of the dev bundle, so we
# include that instead of the (arch-specific) bundle itself in sha calculation.
cp LICENSE.txt "$TARGET_DIR"
cp meteor "$TARGET_DIR/bin"
-CPR engine "$TARGET_DIR"
+CPR tools "$TARGET_DIR"
CPR examples "$TARGET_DIR"
# Trim tests and unfinished examples.
-rm -rf "$TARGET_DIR"/engine/tests
+rm -rf "$TARGET_DIR"/tools/tests
rm -rf "$TARGET_DIR"/examples/unfinished
rm -rf "$TARGET_DIR"/examples/other
# mark directory with current git sha
git rev-parse HEAD > "$TARGET_DIR/.git_version.txt"
-# generate engine version: directory hash that depends only on file
+# generate tools version: directory hash that depends only on file
# contents but nothing else, eg modification time
-echo -n "Computing engine version... "
-ENGINE_VERSION=$(git ls-tree HEAD LICENSE.txt meteor engine examples | shasum | cut -f 1 -d " ") # shasum's output looks like: 'SHA -'
-echo $ENGINE_VERSION
-echo -n "$ENGINE_VERSION" > "$TARGET_DIR/.engine_version.txt"
+echo -n "Computing tools version... "
+TOOLS_VERSION=$(git ls-tree HEAD LICENSE.txt meteor tools examples | shasum | cut -f 1 -d " ") # shasum's output looks like: 'SHA -'
+echo $TOOLS_VERSION
+echo -n "$TOOLS_VERSION" > "$TARGET_DIR/.tools_version.txt"
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -107,7 +107,7 @@ var rpmUpgrade = function () {
};
Fiber(function () {
- console.log("Upgrading to Engine Meteor in " + prefix + "!");
+ console.log("Upgrading to Tools Meteor in " + prefix + "!");
if (package_stamp === 'tar') {
macUpgrade();
} else if (package_stamp === 'deb') {
@@ -0,0 +1 @@
+https://warehouse.meteor.com/tools/c3cdeb9f118c5241ca6a4f1d5b88aa04f0c08ab7
File renamed without changes.
File renamed without changes.
@@ -39,14 +39,14 @@ if [ ! -x "$HOME/.meteor/meteor" ]; then
fi
fi
- # This returns something like https://warehouse.meteor.com/engines/db68972b9d239a95bffa3abe652d1e17815dba91
+ # This returns something like https://warehouse.meteor.com/tools/db68972b9d239a95bffa3abe652d1e17815dba91
ROOT_URL="$(curl -s --fail $BOOTSTRAP_URL)"
- TARBALL_URL="${ROOT_URL}/meteor-engine-bootstrap-${UNAME}-${ARCH}.tar.gz"
+ TARBALL_URL="${ROOT_URL}/meteor-tools-bootstrap-${UNAME}-${ARCH}.tar.gz"
INSTALL_TMPDIR="$HOME/.meteor-install-tmp"
rm -rf "$INSTALL_TMPDIR"
mkdir "$INSTALL_TMPDIR"
- echo 'This is your first time using Meteor! Downloading the engine now.'
+ echo 'This is your first time using Meteor! Downloading the tools now.'
curl --progress-bar --fail "$TARBALL_URL" | tar -xzf - -C "$INSTALL_TMPDIR"
# bomb out if it didn't work, eg no net
test -x "${INSTALL_TMPDIR}/.meteor/meteor"
File renamed without changes.
File renamed without changes.
@@ -71,27 +71,27 @@ var noneWithPrefix = function(s3, prefix) {
return !_.isEmpty(files.Body.ListBucketResult.Contents);
};
-// publish a given engine, copying multiple files from
+// publish a given tools, copying multiple files from
// s3://com.meteor.warehouse/RELEASE/unpublished/ to
-// s3://com.meteor.warehouse/engines/VERSION/
-var publishEngine = function(s3, release, version) {
- var destPath = ["engines", version].join("/");
+// s3://com.meteor.warehouse/tools/VERSION/
+var publishTools = function(s3, release, version) {
+ var destPath = ["tools", version].join("/");
- process.stdout.write("engine " + version + ": ");
+ process.stdout.write("tools " + version + ": ");
if (noneWithPrefix(s3, destPath)) {
console.log("already published");
return;
} else {
- publishedArtifacts.push("engine " + version);
+ publishedArtifacts.push("tools " + version);
console.log("publishing");
}
- var engineArtifacts = s3.ListObjects({
+ var toolsArtifacts = s3.ListObjects({
BucketName: "com.meteor.warehouse",
- Prefix: ["unpublished", release, "meteor-engine-"].join("/")
+ Prefix: ["unpublished", release, "meteor-tools-"].join("/")
}).Body.ListBucketResult.Contents;
- parallelEach(engineArtifacts, function (artifact) {
+ parallelEach(toolsArtifacts, function (artifact) {
var sourceKey = artifact.Key;
var filename = _.last(sourceKey.split("/"));
var destKey = [destPath, filename].join("/");
@@ -178,7 +178,7 @@ var main = function() {
var release = getGitSha();
var s3 = configureS3();
var manifest = getManifest(s3, release);
- publishEngine(s3, release, manifest.engine);
+ publishTools(s3, release, manifest.tools);
parallelEach(manifest.packages, function(version, name) {
publishPackage(s3, release, name, version);
});
File renamed without changes.
@@ -7,7 +7,7 @@ trap 'echo FAILED' EXIT
METEOR_DIR=$(pwd)/..
# run tests
-./node.sh $METEOR_DIR/engine/tests/test_bundler.js
+./node.sh $METEOR_DIR/tools/tests/test_bundler.js
# cleanup trap, and print "SUCCESS"
trap - EXIT
@@ -23,11 +23,11 @@ if [ "$1" == "--global" ]; then
fi
if [ "$TEST_WAREHOUSE_DIR" ]; then
- # The point of this testing script is to test the engine, so we make
+ # The point of this testing script is to test the tools, so we make
# sure (in lib/meteor.js) to not springboard if TEST_WAREHOUSE_DIR is
# set. This is a random release that we pass to --release on all
# commands (in case TEST_WAREHOUSE_DIR) is set. This could break if
- # this specified release is incompatible with the current engine, in
+ # this specified release is incompatible with the current tools, in
# which case you can build and publish a new release and set it here.
TEST_RELEASE="0.6.0"
File renamed without changes.
File renamed without changes.
@@ -12,14 +12,14 @@ make_temp_dir() {
mktemp -d -t $1.XXXXXX
}
-## Test the Meteor CLI from an installed engine (tests loading packages
+## Test the Meteor CLI from an installed tools (tests loading packages
## into the warehouse). Notably
TEST_TMPDIR=$(make_temp_dir meteor-installed-cli-tests)
-ENGINE_DIR="$TEST_TMPDIR/engine-tree"
-TARGET_DIR="$ENGINE_DIR" admin/build-engine-tree.sh
+TOOLS_DIR="$TEST_TMPDIR/tools-tree"
+TARGET_DIR="$TOOLS_DIR" admin/build-tools-tree.sh
export TEST_WAREHOUSE_DIR=$(make_temp_dir meteor-installed-cli-tests-warehouse) # run with empty warehouse
-export METEOR_DIR="$ENGINE_DIR/bin"
+export METEOR_DIR="$TOOLS_DIR/bin"
./cli-test.sh
unset TEST_WAREHOUSE_DIR
unset METEOR_DIR
@@ -1,40 +0,0 @@
-#!/bin/bash
-
-set -e
-
-# cd to top level dir
-cd `dirname $0`
-cd ../..
-TOPDIR=$(pwd)
-
-UNAME=$(uname)
-ARCH=$(uname -m)
-
-ENGINE_TMPDIR=$(mktemp -d -t meteor-build-release-XXXXXXXX)
-trap 'rm -rf "$ENGINE_TMPDIR" >/dev/null 2>&1' 0
-
-# build the engine in a temporary directory. after its built we know
-# its version so rename the directory.
-mkdir -p "$ENGINE_TMPDIR/.meteor/engines"
-export TARGET_DIR="$ENGINE_TMPDIR/.meteor/engines/new"
-$TOPDIR/tools/admin/build-engine-tree.sh
-ENGINE_VERSION=$(cat $TARGET_DIR/.engine_version.txt)
-mv "$TARGET_DIR" "$ENGINE_TMPDIR/.meteor/engines/$ENGINE_VERSION"
-
-ln -s "$ENGINE_VERSION" "$ENGINE_TMPDIR/.meteor/engines/latest"
-ln -s engines/latest/bin/meteor "$ENGINE_TMPDIR/.meteor/meteor"
-
-# tar it up
-OUTDIR="$TOPDIR/dist/engine"
-mkdir -p "$OUTDIR"
-
-ENGINE_TARBALL="$OUTDIR/meteor-engine-${ENGINE_VERSION}-${UNAME}-${ARCH}.tar.gz"
-echo "Tarring engine to: $ENGINE_TARBALL"
-tar -C "$ENGINE_TMPDIR/.meteor/engines" --exclude .meteor/local -czf "$ENGINE_TARBALL" "$ENGINE_VERSION"
-
-ENGINE_BOOTSTRAP_TARBALL="$OUTDIR/meteor-engine-bootstrap-${UNAME}-${ARCH}.tar.gz"
-echo "Tarring engine bootstrap to: $ENGINE_BOOTSTRAP_TARBALL"
-tar -C "$ENGINE_TMPDIR" --exclude .meteor/local -czf "$ENGINE_BOOTSTRAP_TARBALL" .meteor
-
-# A hacky (?) way to pass $ENGINE_VERSION back into build-release.sh
-echo $ENGINE_VERSION > $TOPDIR/.engine_version
@@ -1 +0,0 @@
-https://warehouse.meteor.com/engines/c3cdeb9f118c5241ca6a4f1d5b88aa04f0c08ab7
File renamed without changes.
@@ -3,7 +3,7 @@
// /static [served by node for now]
// /static_cacheable [cache-forever files, served by node for now]
// /server [XXX split out into a package]
-// server.js, .... [contents of engine/server]
+// server.js, .... [contents of tools/server]
// node_modules [for now, contents of (dev_bundle)/lib/node_modules]
// /app.html
// /app [user code]
@@ -702,7 +702,7 @@ _.extend(Bundle.prototype, {
where: 'internal',
hash: self._hash(app_html)
});
- dependencies_json.core.push(path.join('engine', 'app.html.in'));
+ dependencies_json.core.push(path.join('tools', 'app.html.in'));
// --- Documentation, and running from the command line ---
File renamed without changes.
File renamed without changes.
File renamed without changes.
Oops, something went wrong.

0 comments on commit 8a79edb

Please sign in to comment.