Set 'this' to the global object when running in node.js.

Fixes #589.
Merge branch 'nodejsglobal' of git://github.com/TomiBelan/traceur-compiler into TomiBelan-nodejsglobal

Conflicts:
	bin/traceur.js
Node.js API support source maps
Fixup formatting and comments from reviews of recent patches

Review URL: https://github.com/google/traceur-compiler/pull/623

Closes #623.
Upgrade to rsvp 3.0.1.

3.0 did not publish the es6 lib; 3.0.1 fixes that.
The async() is exported from a different point in the lib now.

Fixes Issue #618.

Review URL: https://github.com/google/traceur-compiler/pull/624

Closes #624.
Put bin/traceur-runtime.js in npm

The npm package now contains bin/traceur-runtime.js instead of src/runtime/runtime.js. Previously, users could use the package to compile multiple modules into one ES5 file, but didn't have the necessary runtime code from src/runtime/modules.js to use the result.

The file is created with a npm prepublish script. npm runs this script during `npm publish`, `npm pack` and `npm install --local`. Traceur's Makefile uses `npm install --local`, so this is a bit tricky.

Fixes #587.

Review URL: https://github.com/google/traceur-compiler/pull/592

Closes #592, closes #587.
Fix Windows build

The script parts in package.json are platform dependent and the
bash if syntax does not work on Windows.
Replace git checkout with git show in Makefile
Allow commonjs modules to use module.exports directly

When using CommonJsModuleTransformer, the module can either use the import statement, or the "old" require() function. This allows the same thing for exports. If a module doesn't use any export statements, it can still export values the pre-ES6 way by assigning to exports.foo or module.exports. Traceur users can migrate to ES6 export statements gradually instead of all at once.

Fixes #598.

Review URL: https://github.com/google/traceur-compiler/pull/629

Closes #629, closes #598.
Handle error code, stdout and stderr for prepublish script

Review URL: https://github.com/google/traceur-compiler/pull/631

Closes #631.
Repl: Make sure we use the same loader everywhere

Move the repl demo code into a module and use its imports to import all of traceur. This ensures that the
repl uses the same version of Traceur throughout the repl demo.

Fixes #609

Review URL: https://github.com/google/traceur-compiler/pull/633

Closes #633, closes #609.
wip
Remove System.normalResolve(); use names not urls in Loader.

System.normalResolve() was incorrect, we should be calling normalize() in all cases.
System.locate() should only be called just before fetch().
Fixes #394, Fixes #393

Review URL: https://github.com/google/traceur-compiler/pull/636

Closes #636, closes #394, closes #393.
Revert "wip"

This reverts commit 81f05377583c8a13b03c2449a4faf15e9bc91ce8.
The patch from another incomplete branch got committed with
a correct patch for PR #636
Rename AttachReferrerNameTransformer to AttachModuleNameTransformer.
This should have been in PR #636; I don't know how it was not.
Move .locate() from System to LoaderHooks.

This function is called by the Loader before fetch();
it is essential private API between Loader and LoaderHooks.

Review URL: https://github.com/google/traceur-compiler/pull/638

Closes #638.
transcode.js uses wrong options object

Review URL: https://github.com/google/traceur-compiler/pull/635

Closes #635.
Convert node/interperter.js to use Loader.

Add test-interpreter target to verify that the compile at least runs.

Fixes Issue #614

Review URL: https://github.com/google/traceur-compiler/pull/625

Closes #625.
Implement System.referrerName for Loader normalization.

See @guybedford's proposal on https://github.com/jorendorff/js-loaders/issues/89.
If System.referrerName has a value, use it to normalize names.
@guybedford used System.parentName, we pick another value to avoid
collisions.

Rename ModuleSymbol.url to ModuleSymbol.moduleName.
Several error messages improved as a side-effect (now have file paths).

Review URL: https://github.com/google/traceur-compiler/pull/641

Closes #641.
Add command line option --referrer <name>, sets System.referrer for --out files.

Rename ModuleTransformer .referrerName to .moduleName.
Pass traceur.options through to inlineAndCompile().
Use the IIFE argument to modules.js to set global (window or node global).
Add a handy Makefile rule test/unit/%-run to run one test.
Move registerModule into System.

Review URL: https://github.com/google/traceur-compiler/pull/642

Closes #642.