[
  {
    "path": ".gitignore",
    "content": "*.gem\nGemfile.lock\ntmp/\n"
  },
  {
    "path": ".travis.yml",
    "content": "language: ruby\ncache: bundler\nsudo: false\n\nscript: ./script/test\nafter_success: ./script/deploy\n\nenv:\n  global:\n    secure: \"QQRK8r/bp7FY8gDAPKywoiUkUSmW5gjrV4d1CM8IguncenjAy0HKGrOy0bWMLj0iz211AuxVvofk6c7B3410ILIjbGgMlPNFe8AGlZhL5lTIIc3D4SxEJ5t/cGQ/BCOyN+IG5qvgYBjwcRQm56NNOhwIHWYS6noAQOWfjafxL3I=\"\n  matrix:\n    - BUILD_SOURCE_GEM=1\n    - VALIDATE_TRAVIS=1\n    - SOURCE_VERSION=\"~>4.0.0\"\n    - SOURCE_VERSION=\"~>4.1.0\"\n    - SOURCE_VERSION=\"~>4.2.0\"\n    - SOURCE_VERSION=\"~>4.3.0\"\n    - SOURCE_VERSION=\"~>4.4.0\"\n    - SOURCE_VERSION=\"~>4.5.0\"\n    - SOURCE_VERSION=\"~>4.6.0\"\n    - SOURCE_VERSION=\"~>4.7.0\"\n    - SOURCE_VERSION=\"~>5.0.0\"\n    - SOURCE_VERSION=\"~>5.1.0\"\n    - SOURCE_VERSION=\"~>5.2.0\"\n    - SOURCE_VERSION=\"~>5.3.0\"\n    - SOURCE_VERSION=\"~>5.4.0\"\n    - SOURCE_VERSION=\"~>5.6.0\"\n    - SOURCE_VERSION=\"~>5.8.0\"\n\nmatrix:\n  include:\n    - rvm: 2.0.0\n      env:\n    - rvm: 2.1\n      env:\n    - rvm: 2.2\n      env:\n    - rvm: 2.3.0\n      env:\n  allow_failures:\n    - env: VALIDATE_TRAVIS=1\n"
  },
  {
    "path": "Gemfile",
    "content": "source 'https://rubygems.org'\ngemspec path: ENV['PWD']\n\ngem 'babel-source', ENV['SOURCE_VERSION']\n"
  },
  {
    "path": "LICENSE",
    "content": "Copyright (c) 2015 Joshua Peek\n\nPermission is hereby granted, free of charge, to any person obtaining\na copy of this software and associated documentation files (the\n\"Software\"), to deal in the Software without restriction, including\nwithout limitation the rights to use, copy, modify, merge, publish,\ndistribute, sublicense, and/or sell copies of the Software, and to\npermit persons to whom the Software is furnished to do so, subject to\nthe following conditions:\n\nThe above copyright notice and this permission notice shall be\nincluded in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\nEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\nMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\nNONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE\nLIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION\nOF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION\nWITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n"
  },
  {
    "path": "MAINTAINING.md",
    "content": "# Maintaining\n\n## Releasing a new version\n\nThis project follows [semver](http://semver.org/). Any gem dependency changes\nwill require a new major release.\n\n### Make a release commit\n\nTo prepare the release commit, edit the\n[lib/babel/transpiler/version.rb](https://github.com/babel/ruby-babel-transpiler/blob/master/lib/babel/transpiler/version.rb)\nconstant. Then make a single commit with the description as\n\"Ruby Babel Transpiler 1.x.x\". Tag the commit with `v1.x.x`. Finally, build the gem and\npush it to RubyGems.\n\n``` sh\n$ git pull\n$ vim lib/babel/transpiler/version.rb\n$ git add lib/babel/transpiler/version.rb\n$ git commit -m \"Ruby Babel Transpiler 1.x.x\"\n$ git tag v1.x.x\n$ git push\n$ git push --tags\n$ gem build babel-transpiler.gemspec\n$ gem push babel-transpiler*.gem\n```\n"
  },
  {
    "path": "README.md",
    "content": "# Ruby Babel Transpiler\n\nRuby Babel is a bridge to the [JS Babel transpiler](https://babeljs.io).\n\n``` ruby\nrequire 'babel/transpiler'\nBabel::Transpiler.transform File.read(\"foo.es6\")\n```\n\n## Installation\n\n``` sh\n$ gem install babel-transpiler\n```\n\n## Dependencies\n\nThis library depends on the `babel-source` gem which is updated any time a new version of [Babel](https://babeljs.io) is released.\n\n### ExecJS\n\nThe [ExecJS](https://github.com/rails/execjs) library is used to automatically choose the best JavaScript engine for your platform. Check out its [README](https://github.com/rails/execjs/blob/master/README.md) for a complete list of supported engines.\n"
  },
  {
    "path": "SOURCE-BUILDS.md",
    "content": "# Babel Source Builds\n\nThe Ruby transpiler bridge is just a thin [ExecJS](https://github.com/rails/execjs) wrapper around the [Babel](https://babeljs.io) JS source. The source itself is redistributed as a  [babel-source](https://rubygems.org/gems/babel-source) RubyGem with the corresponding version. This means users can easily upgrade to the latest Babel anytime its released while maintaining Ruby API compatibility.\n\nBabel JS releases tend be released more frequently than changes to the Ruby bridge itself. So theres some automation behind releasing the source gems.\n\n## CI gem builds\n\n`BUILD_SOURCE_GEM=1` is a special entry in the Travis build matrix that automatically builds and tests unpublished source gems.\n\nA list of *local source versions* is maintained under the `source-versions/` directory. This listing is diff'd against the [published release list on rubygems.org](https://rubygems.org/gems/babel-source/versions) to get the subset of unpublished gems that should be tested.\n\nTo test a new release, `touch source-versions/1.2.3`, commit the file and push the changes.\n\nOn the Travis build matrix, see the `BUILD_SOURCE_GEM=1` job.\n\n[![](https://cloud.githubusercontent.com/assets/137/6420712/347d80cc-be8e-11e4-9114-1bb2991c933d.png)](https://travis-ci.org/babel/ruby-babel-transpiler/builds/52399555)\n\nThis job runs the [`build-gem`](https://github.com/babel/ruby-babel-transpiler/blob/master/script/build-gem) script which fetches the [babel/babel](https://github.com/babel/babel) for the version and builds a local `.gem` file. The [`test-gem`](https://github.com/babel/ruby-babel-transpiler/blob/master/script/test-gem) then runs the test suite against the gem. This catches any changes in the babel build process or API changes that may need to be made to the Ruby bridge before releasing.\n\n[![](https://cloud.githubusercontent.com/assets/137/6420733/626d226c-be8e-11e4-8c93-59dd17bab8a1.png)](https://travis-ci.org/babel/ruby-babel-transpiler/jobs/52399556)\n\n\n### CI gem releases\n\nWhile any fork can test changes against the source gem building code path, `master` has a special deployment designation.\n\nAny unreleased source gem pushed to `master` will be automatically published to RubyGems via a Travis `after_success` [`deploy`](https://github.com/babel/ruby-babel-transpiler/blob/master/script/deploy) script. Unfortunately, none of the [official Travis deployment providers](http://docs.travis-ci.com/user/deployment/) could be used. But that may change in the future.\n\nSo core contributors may release a new source version by touching `source-versions/1.2.3` and committing to `master`. No need to worry about special RubyGem permissions.\n\n\n### PR release requests\n\nTo complete the automation workflow, \"release requests\" are automatically published anytime a new tag is pushed to [babel/babel](https://github.com/babel/babel/releases). Contributors just should verify the build is green and should merge any new release.\n\n[![](https://cloud.githubusercontent.com/assets/137/6420592/0827ad96-be8d-11e4-8345-de7c8bc05621.png)](https://github.com/babel/ruby-babel-transpiler/pull/111/files)\n\nA [babel/babel](https://github.com/babel/babel/releases) Webhook is setup to POST to a Heroku instance running the [pr-release](https://github.com/babel/ruby-babel-transpiler/blob/heroku/pr-release) script. Its only responsible for opening a PR with a new `source-versions/1.x.x` file. To avoid merge conflicts, the local versions are tracked as individual files rather than a single file with a list of versions.\n\nShould the Webhook fail or a PR need to be reopened for an older version, this can all be done manually with any GitHub user or fork. Theres nothing special about the bot account or its permissions.\n"
  },
  {
    "path": "babel-source.gemspec.erb",
    "content": "Gem::Specification.new do |s|\n  s.name = 'babel-source'\n  s.version = \"<%= version %>\"\n  s.date = Time.at(<%= date %>)\n\n  s.summary = \"Babel JS source\"\n  s.homepage = \"https://github.com/babel/ruby-babel-transpiler\"\n  s.license = \"MIT\"\n\n  s.files = [\n    'LICENSE',\n    'lib/babel.js',\n    'lib/babel/external-helpers.js',\n    'lib/babel/polyfill.js',\n    'lib/babel/source.rb'\n  ]\n\n  s.authors = ['Sebastian McKenzie']\n  s.email   = 'sebmck@gmail.com'\nend\n"
  },
  {
    "path": "babel-transpiler.gemspec",
    "content": "require File.expand_path(\"../lib/babel/transpiler/version.rb\", __FILE__)\n\nGem::Specification.new do |s|\n  s.name    = 'babel-transpiler'\n  s.version = Babel::Transpiler::VERSION\n\n  s.homepage    = \"https://github.com/babel/ruby-babel-transpiler\"\n  s.summary     = \"Ruby Babel JS Compiler\"\n  s.description = <<-EOS\n    Ruby Babel is a bridge to the JS Babel transpiler.\n  EOS\n  s.license = \"MIT\"\n\n  s.files = [\n    'lib/babel-transpiler.rb',\n    'lib/babel/transpiler.rb',\n    'lib/babel/transpiler/version.rb',\n    'LICENSE'\n  ]\n\n  s.add_dependency 'babel-source', '>= 4.0', '< 6'\n  s.add_dependency 'execjs', '~> 2.0'\n  s.add_development_dependency 'minitest', '~> 5.5'\n\n  s.authors = ['Joshua Peek']\n  s.email   = 'josh@joshpeek.com'\nend\n"
  },
  {
    "path": "lib/babel/source.rb.erb",
    "content": "module Babel\n  module Source\n    VERSION = \"<%= version %>\"\n    DATE = Time.at(<%= date %>)\n    PATH = File.expand_path(\"../..\", __FILE__)\n  end\nend\n"
  },
  {
    "path": "lib/babel/transpiler/version.rb",
    "content": "module Babel\n  module Transpiler\n    VERSION = \"0.7.0\"\n  end\nend\n"
  },
  {
    "path": "lib/babel/transpiler.rb",
    "content": "require 'execjs'\nrequire 'babel/source'\nrequire 'babel/transpiler/version'\n\nmodule Babel\n  module Transpiler\n    def self.version\n      VERSION\n    end\n\n    def self.source_version\n      Source::VERSION\n    end\n\n    def self.source_path\n      Source::PATH\n    end\n\n    def self.script_path\n      File.join(source_path, \"babel.js\")\n    end\n\n    def self.context\n      @context ||= ExecJS.compile(\"var self = this; \" + File.read(script_path))\n    end\n\n    def self.transform(code, options = {})\n      context.call('babel.transform', code, options.merge('ast' => false))\n    end\n  end\nend\n"
  },
  {
    "path": "lib/babel-transpiler.rb",
    "content": "require 'babel/transpiler'\n"
  },
  {
    "path": "script/build-gem",
    "content": "#!/bin/bash\n\nset -e\nset -x\n\nVERSION=\"$1\"\nGEM_VERSION=$(./script/gem-version $VERSION)\n\nmkdir -p tmp/\npushd tmp/\n\nif [ ! -d babel ]; then\n  git clone https://github.com/babel/babel\nfi\n\npushd babel/\ngit fetch origin\n\ngit checkout --quiet \"v$VERSION\"\nmake bootstrap build-dist\n\nDATE=$(git show --format=%at | head -n1)\n\npopd\npopd\n\ndir=\"tmp/babel-source-$VERSION\"\nmkdir -p \"$dir/lib/babel\"\ncp \"tmp/babel/packages/babel/dist/browser.js\" \"$dir/lib/babel.js\"\ncp \"tmp/babel/packages/babel/dist/external-helpers.js\" \"$dir/lib/babel/external-helpers.js\"\ncp \"tmp/babel/packages/babel/dist/polyfill.js\" \"$dir/lib/babel/polyfill.js\"\n\ncp \"tmp/babel/LICENSE\" \"$dir/LICENSE\"\n./script/eval-erb-template \"babel-source.gemspec.erb\" \"$GEM_VERSION\" \"$DATE\" > \"$dir/babel-source.gemspec\"\n./script/eval-erb-template \"lib/babel/source.rb.erb\" \"$GEM_VERSION\" \"$DATE\" > \"$dir/lib/babel/source.rb\"\n\npushd \"$dir\"\ngem build babel-source.gemspec\npopd\n\nmkdir -p tmp/vendor/cache\ncp \"$dir/babel-source-$GEM_VERSION.gem\" \"tmp/vendor/cache\"\n"
  },
  {
    "path": "script/deploy",
    "content": "#!/bin/bash\n\nset -e\n\nif [ -n \"$TRAVIS\" ] && ([ \"$TRAVIS_SECURE_ENV_VARS\" != \"true\" ] || [ \"$TRAVIS_BRANCH\" != \"master\" ] || [ \"$TRAVIS_PULL_REQUEST\" != \"false\" ] || [ -z \"$BUILD_SOURCE_GEM\" ])\nthen\n  echo \"skipping deploy\" >&2\n  exit 0\nfi\n\necho \"deploying unpublished versions\" >&2\n\nif [ \"$TRAVIS_SECURE_ENV_VARS\" = \"true\" ]; then\n  cat << EOF > ~/.gem/credentials\n---\n:rubygems_api_key: $RUBYGEMS_API_KEY\nEOF\n  chmod 0600 ~/.gem/credentials\nfi\n\nfor source_version in $(./script/unpublished-source-versions)\ndo\n  if [ ! -f \"tmp/vendor/cache/babel-source-$source_version.gem\" ]; then\n    ./script/test-gem \"$version\"\n  fi\n  gem push \"tmp/vendor/cache/babel-source-$source_version.gem\"\ndone\n"
  },
  {
    "path": "script/eval-erb-template",
    "content": "#!/usr/bin/env ruby\n\nrequire 'erb'\nversion, date = ARGV[1], ARGV[2]\nputs ERB.new(File.read(ARGV[0])).result(binding)\n"
  },
  {
    "path": "script/gem-version",
    "content": "#!/bin/bash\nif [ -n \"$1\" ]; then\n  echo $1 | sed s/-/./g\nelse\n  sed s/-/./g\nfi\n"
  },
  {
    "path": "script/local-source-versions",
    "content": "#!/bin/bash\nls ./source-versions | sort\n"
  },
  {
    "path": "script/published-source-versions",
    "content": "#!/usr/bin/env ruby\n\nrequire 'json'\nrequire 'open-uri'\n\nurl = \"https://rubygems.org/api/v1/versions/babel-source.json\"\nputs JSON.parse(open(url).read).map { |v| v[\"number\"] }.reverse\n"
  },
  {
    "path": "script/test",
    "content": "#!/bin/bash\n\nset -e\n\nbundle exec ruby -w test/test_babel_transpiler.rb\n\nif [ -n \"$VALIDATE_TRAVIS\" ]; then\n  ./script/validate-travis\nfi\n\nif [ -n \"$BUILD_SOURCE_GEM\" ]; then\n  for version in $(./script/unpublished-source-versions)\n  do\n    ./script/test-gem \"$version\"\n  done\nfi\n"
  },
  {
    "path": "script/test-gem",
    "content": "#!/bin/bash\n\nset -e\nset -x\n\nexport VERSION=\"$1\"\nexport SOURCE_VERSION=$(./script/gem-version $VERSION)\n\nif [ ! -f \"tmp/vendor/cache/babel-source-$SOURCE_VERSION.gem\" ]; then\n  ./script/build-gem \"$VERSION\"\nfi\n\ncp Gemfile tmp/Gemfile\nrm -f tmp/Gemfile.lock\n\nexport BUNDLE_GEMFILE=\"tmp/Gemfile\"\nbundle install --no-prune\n\nbundle exec ruby test/test_babel_transpiler.rb\n"
  },
  {
    "path": "script/unpublished-source-versions",
    "content": "#!/bin/bash\ncomm -13 <(./script/published-source-versions | sort) <(./script/local-source-versions | ./script/gem-version | sort)\n"
  },
  {
    "path": "script/validate-travis",
    "content": "#!/usr/bin/env ruby\n\nrequire 'set'\nrequire 'yaml'\n\ndef version_constraints(versions)\n  Set.new(versions.compact.map { |v|\n    v =~ /^(\\d+)\\.(\\d+)\\.(\\d+)$/ && v.sub(/^(\\d+)\\.(\\d+)\\.(\\d+)$/, '~>\\1.\\2.0')\n  }.compact)\nend\n\npublished = version_constraints(`./script/published-source-versions`.split(\"\\n\"))\nlocal = version_constraints(`./script/local-source-versions`.split(\"\\n\"))\n\nconfig = YAML.load(File.read(\".travis.yml\"))\ntravis = Set.new(config[\"env\"][\"matrix\"].map { |s| s[/^SOURCE_VERSION=\"(.+)\"$/, 1] }.compact)\n\nmissing = (published & local) - travis\n\nif missing.any?\n  abort \"Add the following envs to .travis.yml: \\n\" +\n    missing.map { |v| \"- SOURCE_VERSION=\\\"#{v}\\\"\" }.join(\"\\n\")\nend\n"
  },
  {
    "path": "source-versions/4.0.1",
    "content": ""
  },
  {
    "path": "source-versions/4.0.2",
    "content": ""
  },
  {
    "path": "source-versions/4.1.1",
    "content": ""
  },
  {
    "path": "source-versions/4.2.0",
    "content": ""
  },
  {
    "path": "source-versions/4.2.1",
    "content": ""
  },
  {
    "path": "source-versions/4.3.0",
    "content": ""
  },
  {
    "path": "source-versions/4.4.1",
    "content": ""
  },
  {
    "path": "source-versions/4.4.2",
    "content": ""
  },
  {
    "path": "source-versions/4.4.3",
    "content": ""
  },
  {
    "path": "source-versions/4.4.4",
    "content": ""
  },
  {
    "path": "source-versions/4.4.5",
    "content": ""
  },
  {
    "path": "source-versions/4.4.6",
    "content": ""
  },
  {
    "path": "source-versions/4.5.0",
    "content": ""
  },
  {
    "path": "source-versions/4.5.2",
    "content": ""
  },
  {
    "path": "source-versions/4.5.3",
    "content": ""
  },
  {
    "path": "source-versions/4.5.4",
    "content": ""
  },
  {
    "path": "source-versions/4.5.5",
    "content": ""
  },
  {
    "path": "source-versions/4.6.0",
    "content": ""
  },
  {
    "path": "source-versions/4.6.1",
    "content": ""
  },
  {
    "path": "source-versions/4.6.2",
    "content": ""
  },
  {
    "path": "source-versions/4.6.3",
    "content": ""
  },
  {
    "path": "source-versions/4.6.4",
    "content": ""
  },
  {
    "path": "source-versions/4.6.5",
    "content": ""
  },
  {
    "path": "source-versions/4.6.6",
    "content": ""
  },
  {
    "path": "source-versions/4.7.0",
    "content": ""
  },
  {
    "path": "source-versions/4.7.1",
    "content": ""
  },
  {
    "path": "source-versions/4.7.10",
    "content": ""
  },
  {
    "path": "source-versions/4.7.11",
    "content": ""
  },
  {
    "path": "source-versions/4.7.12",
    "content": ""
  },
  {
    "path": "source-versions/4.7.13",
    "content": ""
  },
  {
    "path": "source-versions/4.7.14",
    "content": ""
  },
  {
    "path": "source-versions/4.7.15",
    "content": ""
  },
  {
    "path": "source-versions/4.7.16",
    "content": ""
  },
  {
    "path": "source-versions/4.7.2",
    "content": ""
  },
  {
    "path": "source-versions/4.7.3",
    "content": ""
  },
  {
    "path": "source-versions/4.7.4",
    "content": ""
  },
  {
    "path": "source-versions/4.7.5",
    "content": ""
  },
  {
    "path": "source-versions/4.7.6",
    "content": ""
  },
  {
    "path": "source-versions/4.7.7",
    "content": ""
  },
  {
    "path": "source-versions/4.7.8",
    "content": ""
  },
  {
    "path": "source-versions/4.7.9",
    "content": ""
  },
  {
    "path": "source-versions/5.0.0",
    "content": ""
  },
  {
    "path": "source-versions/5.0.0-beta1",
    "content": ""
  },
  {
    "path": "source-versions/5.0.0-beta2",
    "content": ""
  },
  {
    "path": "source-versions/5.0.0-beta3",
    "content": ""
  },
  {
    "path": "source-versions/5.0.0-beta4",
    "content": ""
  },
  {
    "path": "source-versions/5.0.1",
    "content": ""
  },
  {
    "path": "source-versions/5.0.10",
    "content": ""
  },
  {
    "path": "source-versions/5.0.11",
    "content": ""
  },
  {
    "path": "source-versions/5.0.12",
    "content": ""
  },
  {
    "path": "source-versions/5.0.13",
    "content": ""
  },
  {
    "path": "source-versions/5.0.2",
    "content": ""
  },
  {
    "path": "source-versions/5.0.3",
    "content": ""
  },
  {
    "path": "source-versions/5.0.4",
    "content": ""
  },
  {
    "path": "source-versions/5.0.5",
    "content": ""
  },
  {
    "path": "source-versions/5.0.6",
    "content": ""
  },
  {
    "path": "source-versions/5.0.7",
    "content": ""
  },
  {
    "path": "source-versions/5.0.8",
    "content": ""
  },
  {
    "path": "source-versions/5.0.9",
    "content": ""
  },
  {
    "path": "source-versions/5.1.0",
    "content": ""
  },
  {
    "path": "source-versions/5.1.1",
    "content": ""
  },
  {
    "path": "source-versions/5.1.10",
    "content": ""
  },
  {
    "path": "source-versions/5.1.11",
    "content": ""
  },
  {
    "path": "source-versions/5.1.12",
    "content": ""
  },
  {
    "path": "source-versions/5.1.13",
    "content": ""
  },
  {
    "path": "source-versions/5.1.2",
    "content": ""
  },
  {
    "path": "source-versions/5.1.3",
    "content": ""
  },
  {
    "path": "source-versions/5.1.4",
    "content": ""
  },
  {
    "path": "source-versions/5.1.5",
    "content": ""
  },
  {
    "path": "source-versions/5.1.6",
    "content": ""
  },
  {
    "path": "source-versions/5.1.7",
    "content": ""
  },
  {
    "path": "source-versions/5.1.8",
    "content": ""
  },
  {
    "path": "source-versions/5.1.9",
    "content": ""
  },
  {
    "path": "source-versions/5.2.0",
    "content": ""
  },
  {
    "path": "source-versions/5.2.1",
    "content": ""
  },
  {
    "path": "source-versions/5.2.10",
    "content": ""
  },
  {
    "path": "source-versions/5.2.11",
    "content": ""
  },
  {
    "path": "source-versions/5.2.12",
    "content": ""
  },
  {
    "path": "source-versions/5.2.13",
    "content": ""
  },
  {
    "path": "source-versions/5.2.14",
    "content": ""
  },
  {
    "path": "source-versions/5.2.15",
    "content": ""
  },
  {
    "path": "source-versions/5.2.16",
    "content": ""
  },
  {
    "path": "source-versions/5.2.17",
    "content": ""
  },
  {
    "path": "source-versions/5.2.2",
    "content": ""
  },
  {
    "path": "source-versions/5.2.6",
    "content": ""
  },
  {
    "path": "source-versions/5.2.7",
    "content": ""
  },
  {
    "path": "source-versions/5.2.8",
    "content": ""
  },
  {
    "path": "source-versions/5.2.9",
    "content": ""
  },
  {
    "path": "source-versions/5.3.0",
    "content": ""
  },
  {
    "path": "source-versions/5.3.1",
    "content": ""
  },
  {
    "path": "source-versions/5.3.2",
    "content": ""
  },
  {
    "path": "source-versions/5.3.3",
    "content": ""
  },
  {
    "path": "source-versions/5.4.0",
    "content": ""
  },
  {
    "path": "source-versions/5.4.1",
    "content": ""
  },
  {
    "path": "source-versions/5.4.2",
    "content": ""
  },
  {
    "path": "source-versions/5.4.3",
    "content": ""
  },
  {
    "path": "source-versions/5.4.4",
    "content": ""
  },
  {
    "path": "source-versions/5.4.5",
    "content": ""
  },
  {
    "path": "source-versions/5.4.6",
    "content": ""
  },
  {
    "path": "source-versions/5.4.7",
    "content": ""
  },
  {
    "path": "source-versions/5.6.0",
    "content": ""
  },
  {
    "path": "source-versions/5.6.1",
    "content": ""
  },
  {
    "path": "source-versions/5.6.11",
    "content": ""
  },
  {
    "path": "source-versions/5.6.12",
    "content": ""
  },
  {
    "path": "source-versions/5.6.13",
    "content": ""
  },
  {
    "path": "source-versions/5.6.14",
    "content": ""
  },
  {
    "path": "source-versions/5.6.15",
    "content": ""
  },
  {
    "path": "source-versions/5.6.16",
    "content": ""
  },
  {
    "path": "source-versions/5.6.17",
    "content": ""
  },
  {
    "path": "source-versions/5.6.18",
    "content": ""
  },
  {
    "path": "source-versions/5.6.19",
    "content": ""
  },
  {
    "path": "source-versions/5.6.2",
    "content": ""
  },
  {
    "path": "source-versions/5.6.20",
    "content": ""
  },
  {
    "path": "source-versions/5.6.3",
    "content": ""
  },
  {
    "path": "source-versions/5.6.4",
    "content": ""
  },
  {
    "path": "source-versions/5.6.5",
    "content": ""
  },
  {
    "path": "source-versions/5.6.6",
    "content": ""
  },
  {
    "path": "source-versions/5.6.7",
    "content": ""
  },
  {
    "path": "source-versions/5.8.0",
    "content": ""
  },
  {
    "path": "source-versions/5.8.1",
    "content": ""
  },
  {
    "path": "source-versions/5.8.10",
    "content": ""
  },
  {
    "path": "source-versions/5.8.11",
    "content": ""
  },
  {
    "path": "source-versions/5.8.12",
    "content": ""
  },
  {
    "path": "source-versions/5.8.13",
    "content": ""
  },
  {
    "path": "source-versions/5.8.14",
    "content": ""
  },
  {
    "path": "source-versions/5.8.15",
    "content": ""
  },
  {
    "path": "source-versions/5.8.16",
    "content": ""
  },
  {
    "path": "source-versions/5.8.17",
    "content": ""
  },
  {
    "path": "source-versions/5.8.18",
    "content": ""
  },
  {
    "path": "source-versions/5.8.19",
    "content": ""
  },
  {
    "path": "source-versions/5.8.2",
    "content": ""
  },
  {
    "path": "source-versions/5.8.23",
    "content": ""
  },
  {
    "path": "source-versions/5.8.24",
    "content": ""
  },
  {
    "path": "source-versions/5.8.25",
    "content": ""
  },
  {
    "path": "source-versions/5.8.26",
    "content": ""
  },
  {
    "path": "source-versions/5.8.27",
    "content": ""
  },
  {
    "path": "source-versions/5.8.28",
    "content": ""
  },
  {
    "path": "source-versions/5.8.29",
    "content": ""
  },
  {
    "path": "source-versions/5.8.3",
    "content": ""
  },
  {
    "path": "source-versions/5.8.30",
    "content": ""
  },
  {
    "path": "source-versions/5.8.31",
    "content": ""
  },
  {
    "path": "source-versions/5.8.32",
    "content": ""
  },
  {
    "path": "source-versions/5.8.33",
    "content": ""
  },
  {
    "path": "source-versions/5.8.34",
    "content": ""
  },
  {
    "path": "source-versions/5.8.35",
    "content": ""
  },
  {
    "path": "source-versions/5.8.4",
    "content": ""
  },
  {
    "path": "source-versions/5.8.5",
    "content": ""
  },
  {
    "path": "source-versions/5.8.6",
    "content": ""
  },
  {
    "path": "source-versions/5.8.7",
    "content": ""
  },
  {
    "path": "source-versions/5.8.8",
    "content": ""
  },
  {
    "path": "source-versions/5.8.9",
    "content": ""
  },
  {
    "path": "test/test_babel_transpiler.rb",
    "content": "require 'minitest/autorun'\nrequire 'babel/transpiler'\n\nclass TestBabelTranspiler < MiniTest::Test\n  def test_source_constants\n    assert Babel::Source::VERSION\n    assert Babel::Source::DATE\n    assert Babel::Source::PATH\n  end\n\n  def test_source_path_directory\n    assert File.directory?(\"#{Babel::Transpiler.source_path}\")\n    assert File.directory?(\"#{Babel::Transpiler.source_path}/babel\")\n    assert File.file?(\"#{Babel::Transpiler.source_path}/babel.js\")\n    assert File.file?(\"#{Babel::Transpiler.source_path}/babel/external-helpers.js\")\n    assert File.file?(\"#{Babel::Transpiler.source_path}/babel/polyfill.js\")\n  end\n\n  def test_script_path_readable\n    path = Babel::Transpiler.script_path\n    assert File.exist?(path)\n    assert File.read(path)\n  end\n\n  def test_version\n    assert Babel::Transpiler.version\n    assert Babel::Transpiler.source_version\n  end\n\n  def test_transform\n    code = Babel::Transpiler.transform(\"[0, 2, 4].map(v => v + 1)\", \"blacklist\" => [\"useStrict\"])[\"code\"]\n    assert_equal [1, 3, 5], ExecJS.exec(\"return #{code}\")\n\n    code = Babel::Transpiler.transform(\"(function f(x, y = 12) { return x + y; })(3)\", \"blacklist\" => [\"useStrict\"])[\"code\"]\n    assert_equal 15, ExecJS.exec(\"return #{code}\")\n  end\n\n  def test_transform_options\n    code = Babel::Transpiler.transform(\"ary.map(v => v + 1)\", \"whitelist\" => [\"useStrict\"])[\"code\"]\n    assert_match(/strict/, code)\n\n    code = Babel::Transpiler.transform(\"ary.map(v => v + 1)\", \"blacklist\" => [\"useStrict\"])[\"code\"]\n    refute_match(/strict/, code)\n\n    assert Babel::Transpiler.transform(\"ary.map(v => v + 1)\", {}.freeze)[\"code\"]\n  end\nend\n"
  }
]