[
  {
    "path": ".gitignore",
    "content": "# See http://help.github.com/ignore-files/ for more about ignoring files.\n#\n# If you find yourself ignoring temporary files generated by your text editor\n# or operating system, you probably want to add a global ignore instead:\n#   git config --global core.excludesfile ~/.gitignore_global\n\n# Ignore bundler config\n.bundle\n\n# Ignore the default SQLite database.\n*.sqlite3\n\n# Ignore all logfiles and tempfiles.\n*/log/*.log\nlog/*.log\n*/tmp\ntmp\n\n.idea\n.sass-cache\n.DS_Store\n"
  },
  {
    "path": ".rspec",
    "content": "--color\n"
  },
  {
    "path": ".ruby-gemset",
    "content": "tnbt\n"
  },
  {
    "path": ".ruby-version",
    "content": "2.1.0\n"
  },
  {
    "path": ".travis.yml",
    "content": "gemfile:\n  - Gemfile\n  - components/annoyance/Gemfile\n  - components/email_signup/Gemfile\n  - components/event_counter/Gemfile\n  - components/teaser/Gemfile\nscript:\n  - ./test.sh\nbefore_install:\n  - \"export DISPLAY=:99.0\"\n  - \"sh -e /etc/init.d/xvfb start\"\n  - cd $(dirname $BUNDLE_GEMFILE)\nrvm:\n  - 2.1.0\n"
  },
  {
    "path": "Gemfile",
    "content": "source \"https://rubygems.org\"\n\ngem \"rails\", \"4.1.8\"\n\npath 'components' do\n  gem \"teaser\"\nend\n\ngroup :test, :development do\n  gem \"rspec-rails\", \"3.1.0\"\n  gem \"capybara\", \"2.4.1\"\n  gem \"sqlite3\", \"1.3.9\"\nend\n\ngroup :production do\n  gem \"pg\"\nend"
  },
  {
    "path": "MIT-LICENSE",
    "content": "Copyright 2012 Stephan Hagemann\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": "README.md",
    "content": "# The Next Big Thing [![Build Status](https://secure.travis-ci.org/shageman/the_next_big_thing.png)](https://secure.travis-ci.org/shageman/the_next_big_thing) [![Dependency Status](https://gemnasium.com/shageman/the_next_big_thing.png)](https://gemnasium.com/shageman/the_next_big_thing) [![Code Climate](https://codeclimate.com/github/shageman/the_next_big_thing.png)](https://codeclimate.com/github/shageman/the_next_big_thing)\n\n## What is this?\n\nA full-fledged portal to announce the next big thing! Jumpstart the PR campaign for your next big thing by standing on the shoulder of a giant: The next big Thing!!\n\n## What is this really?\n\nA sample project showcasing the use of unbuilt Rails Engines and Gems. The entire app has been developed using TDD - follow the commits to see the parts evolve. Current state:\n\n*   `Teaser` provides the web page one sees when running the the_next_big_thing server. It depends on all the other engines.\n*   `Annoyance` contains a service that given a number will give an indication of how annoying that number is.\n*   `EmailSignup` provides a service allowing the storage of email addresses.\n*   `EventCounter` provides a service that can count for any object how many times a particular action has happened.\n*   The main Rails application does not contain any application code: it does not even have an `app` directory. It is soley responsible for encapsulating and mounting the engine in the right place.\n\n##Resources on component-based Rails applications\nTwitter hashtag: #cbra - https://twitter.com/hashtag/cbra\n\nBlog posts:\n\n* http://blog.pivotal.io/pivotal-labs?s=&category=0&post_tag=1505&author=&archives=\n \nPast presentations by Ben Smith and me (mostly on this topic)\n\n* http://confreaks.com/presenters/790-stephan-hagemann\n* http://confreaks.com/presenters/784-ben-smith\n \nThe book I am writing\n\n* https://leanpub.com/cbra\n\n## Running the test suite\n```bash\ngit clone https://github.com/shageman/the_next_big_thing.git\ncd the_next_big_thing\n./build.sh\n```\n\n## Contributing\n\nI highly appreciate it!\n\nFork, pull, create, commit, push, request pull.\n\n## License\n\n    Copyright (c) 2012-2013 Stephan Hagemann\n    twitter.com/shageman\n    %w(stephan.hagemann gmail.com) * \"@\"\n\n    Released under the MIT license. See MIT-LICENSE file for details.\n"
  },
  {
    "path": "Rakefile",
    "content": "#!/usr/bin/env rake\nrequire File.expand_path('../config/application', __FILE__)\nTheNextBigThing::Application.load_tasks\n"
  },
  {
    "path": "bin/bundle",
    "content": "#!/usr/bin/env ruby\nENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)\nload Gem.bin_path('bundler', 'bundle')\n"
  },
  {
    "path": "bin/rails",
    "content": "#!/usr/bin/env ruby\nAPP_PATH = File.expand_path('../../config/application',  __FILE__)\nrequire_relative '../config/boot'\nrequire 'rails/commands'\n"
  },
  {
    "path": "bin/rake",
    "content": "#!/usr/bin/env ruby\nrequire_relative '../config/boot'\nrequire 'rake'\nRake.application.run\n"
  },
  {
    "path": "build.sh",
    "content": "#!/bin/bash\n\nunset BUNDLE_GEMFILE\nresult=0\n\nif [ \"$CI\" == \"true\" ]; then\n  BUNDLE_PATH=\"$HOME/vendor/bundle\"\nfi\n\n# Change working directory to this script's parent directory so we find the right files\ncd \"$( dirname \"${BASH_SOURCE[0]}\" )\"\n\nfor test_script in $(find . -name test.sh); do\n  pushd `dirname $test_script` > /dev/null\n  source \"$HOME/.rvm/scripts/rvm\"\n  rvm use $(cat .ruby-version)@$(cat .ruby-gemset) --create\n  which ruby\n  rvm gemset name\n  ./test.sh\n  result+=$?\n  popd > /dev/null\ndone\n\nif [ $result -eq 0 ]; then\n\techo \"SUCCESS\"\nelse\n\techo \"FAILURE\"\nfi\n\nexit $result\n"
  },
  {
    "path": "components/annoyance/.gitignore",
    "content": ".bundle/\nlog/*.log\npkg/\ntest/dummy/db/*.sqlite3\ntest/dummy/log/*.log\ntest/dummy/tmp/\ntest/dummy/.sass-cache\n"
  },
  {
    "path": "components/annoyance/.rspec",
    "content": "--color\n"
  },
  {
    "path": "components/annoyance/.ruby-gemset",
    "content": "tnbtannoyance\n"
  },
  {
    "path": "components/annoyance/.ruby-version",
    "content": "2.1.0\n"
  },
  {
    "path": "components/annoyance/Gemfile",
    "content": "source \"https://rubygems.org\"\n\ngemspec\n\ngem \"rspec\""
  },
  {
    "path": "components/annoyance/MIT-LICENSE",
    "content": "Copyright 2012 YOURNAME\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": "components/annoyance/README.rdoc",
    "content": "= Annoyance\n\nThis project rocks and uses MIT-LICENSE."
  },
  {
    "path": "components/annoyance/Rakefile",
    "content": "#!/usr/bin/env rake\nbegin\n  require 'bundler/setup'\nrescue LoadError\n  puts 'You must `gem install bundler` and `bundle install` to run rake tasks'\nend\nbegin\n  require 'rdoc/task'\nrescue LoadError\n  require 'rdoc/rdoc'\n  require 'rake/rdoctask'\n  RDoc::Task = Rake::RDocTask\nend\n\nRDoc::Task.new(:rdoc) do |rdoc|\n  rdoc.rdoc_dir = 'rdoc'\n  rdoc.title    = 'AnnoyanceMeter'\n  rdoc.options << '--line-numbers'\n  rdoc.rdoc_files.include('README.rdoc')\n  rdoc.rdoc_files.include('lib/**/*.rb')\nend\n\n\n\n\nBundler::GemHelper.install_tasks\n\nrequire 'rake/testtask'\n\nRake::TestTask.new(:test) do |t|\n  t.libs << 'lib'\n  t.libs << 'test'\n  t.pattern = 'test/**/*_test.rb'\n  t.verbose = false\nend\n\n\ntask :default => :test\n"
  },
  {
    "path": "components/annoyance/annoyance.gemspec",
    "content": "$:.push File.expand_path(\"../lib\", __FILE__)\n\n# Maintain your gem's version:\nrequire \"annoyance/version\"\n\n# Describe your gem and declare its dependencies:\nGem::Specification.new do |s|\n  s.name        = \"annoyance\"\n  s.version     = Annoyance::VERSION\n  s.authors     = [\"Stephan Hagemann\"]\n  s.email       = [\"stephan.hagemann@gmail.com\"]\n  s.summary     = \"A very annoyed gem\"\n  s.description = \"A very annoyed gem\"\n\n  s.files = Dir[\"{app,config,db,lib}/**/*\"] + [\"MIT-LICENSE\", \"Rakefile\", \"README.rdoc\"]\n  s.test_files = Dir[\"spec/**/*\"]\n\n  s.add_development_dependency \"rspec\", \"2.12.0\"\nend\n"
  },
  {
    "path": "components/annoyance/app/models/annoyance/levels.rb",
    "content": "module Annoyance\n  module Levels\n    def self.levels\n      [\n          \"Huh?\",\n          \"What?\",\n          \"Dude!\",\n          \"Hello!?\",\n          \"Somebody home?\",\n          \"Hey, careful with you're typing!\",\n          \"Come on, this is nonsense!\",\n          \"I have almost had enough!\",\n          \"Really?\",\n          %q{<img src=\"/assets/teaser/hair.gif\" alt=\"Hairdo\" title=\"Hairdo\" class=\"gif\" style=\"margin: 0 10px;\">}\n      ]\n    end\n  end\nend"
  },
  {
    "path": "components/annoyance/app/models/annoyance/meter.rb",
    "content": "module Annoyance\n  class Meter\n    attr_accessor :limit\n\n    def initialize(limit)\n      raise ArgumentError unless limit.is_a? Integer\n      @limit = limit\n    end\n\n    def annoyance_level(repetition_count)\n      raise ArgumentError unless limit.is_a? Integer\n      return \"\" if repetition_count <= 0\n\n      repetition_count -= 1\n\n      index = repetition_count * Annoyance::Levels.levels.count/limit.to_f\n      index_to_access = [index, Annoyance::Levels.levels.count - 1].min\n\n      annoyance_level = Annoyance::Levels.levels[index_to_access]\n      annoyance_level + what_to_duplicate(repetition_count, annoyance_level) * emphasis(repetition_count, index)\n    end\n\n    def annoyance_adjusted(text, repetition_count)\n      if repetition_count < limit\n        text + annoyance_level(repetition_count)\n      else\n        annoyance_level(repetition_count)\n      end\n    end\n\n    private\n\n    def emphasis(repetition_count, index)\n      if repetition_count < limit\n        if index - index.to_i != 0\n          (1/(index - index.to_i)).ceil - 1\n        else\n          0\n        end\n      else\n        repetition_count - limit + 1\n      end\n    end\n\n    def what_to_duplicate(repetition_count, annoyance_level)\n      repetition_count < limit ? annoyance_level[-1] : annoyance_level\n    end\n  end\nend\n"
  },
  {
    "path": "components/annoyance/lib/annoyance/engine.rb",
    "content": "module Annoyance\n  class Engine < ::Rails::Engine\n  end\nend\n"
  },
  {
    "path": "components/annoyance/lib/annoyance/version.rb",
    "content": "module Annoyance\n  VERSION = \"0.0.1\"\nend\n"
  },
  {
    "path": "components/annoyance/lib/annoyance.rb",
    "content": "if defined?(Rails)\n  require 'annoyance/engine'\nelse\n  require_relative '../app/models/annoyance/levels'\n  require_relative '../app/models/annoyance/meter'\nend\n\nmodule Annoyance\nend\n"
  },
  {
    "path": "components/annoyance/spec/annoyance/levels_spec.rb",
    "content": "require File.expand_path(\"../../../app/models/annoyance/levels\", __FILE__)\n\nmodule Annoyance\n  describe Annoyance do\n    describe \".levels\" do\n      it \"should be an array of strings\" do\n        Annoyance::Levels.levels.should be_an Array\n        Annoyance::Levels.levels.select {|level| level.is_a? String }.count.should == Annoyance::Levels.levels.count\n      end\n    end\n  end\nend\n\n"
  },
  {
    "path": "components/annoyance/spec/annoyance/meter_spec.rb",
    "content": "require File.expand_path(\"../../../app/models/annoyance/meter\", __FILE__)\n\nmodule Annoyance\n  describe Annoyance::Meter do\n    it \"should be calibrated on initialize\" do\n      meter = Annoyance::Meter.new(10)\n      meter.limit.should == 10\n    end\n\n    it \"should raise if anything but an Integer is given\" do\n      expect {\n        meter = Annoyance::Meter.new(:a)\n      }.to raise_exception ArgumentError\n    end\n\n    describe \"#annoyance_level\" do\n      before do\n        Annoyance::Levels.stub(:levels).and_return(\n            [\n                \"level 1!\",\n                \"level 2!\",\n                \"level 3!\",\n                \"level 4!\",\n            ]\n        )\n      end\n\n      it \"should raise if anything but an Integer is given\" do\n        expect {\n          meter = Annoyance::Meter.new(5).annoyance_level(\"a\")\n        }.to raise_exception ArgumentError\n      end\n\n      it \"should return the description of the appropriate level of annoyance\" do\n        meter = Annoyance::Meter.new(4)\n        meter.annoyance_level(1).should == \"level 1!\"\n        meter.annoyance_level(2).should == \"level 2!\"\n        meter.annoyance_level(3).should == \"level 3!\"\n        meter.annoyance_level(4).should == \"level 4!\"\n      end\n\n      it \"should handle impossible user input gracefully\" do\n        meter = Annoyance::Meter.new(3)\n        meter.annoyance_level(-1).should == \"\"\n      end\n\n\n      it \"should return empty string for count 0\" do\n        meter = Annoyance::Meter.new(99)\n        meter.annoyance_level(0).should == \"\"\n\n        meter = Annoyance::Meter.new(15)\n        meter.annoyance_level(0).should == \"\"\n      end\n\n      it \"should extrapolate from the last appropriate level of annoyance by duplicating the last character\" do\n        meter = Annoyance::Meter.new(8)\n        meter.annoyance_level(1).should == \"level 1!\"\n        meter.annoyance_level(2).should == \"level 1!!\"\n        meter.annoyance_level(3).should == \"level 2!\"\n        meter.annoyance_level(4).should == \"level 2!!\"\n        meter.annoyance_level(5).should == \"level 3!\"\n        meter.annoyance_level(6).should == \"level 3!!\"\n        meter.annoyance_level(7).should == \"level 4!\"\n        meter.annoyance_level(8).should == \"level 4!!\"\n      end\n\n      it \"should extrapolate the last possible input by duplicating the whole result\" do\n        meter = Annoyance::Meter.new(4)\n        meter.annoyance_level(5).should == \"level 4!level 4!\"\n        meter.annoyance_level(6).should == \"level 4!level 4!level 4!\"\n      end\n    end\n\n    describe \"#annoyance_adjusted\" do\n      before do\n        Annoyance::Levels.stub(:levels).and_return(\n            [\n                \"level 1!\",\n                \"level 2!\"\n            ]\n        )\n      end\n\n      context \"when this limit is not yet reached\" do\n        it \"should annoyance adjust a given text by duplicating the last character\" do\n          meter = Annoyance::Meter.new(2)\n          meter.annoyance_adjusted(\"text.\", 1).should == \"text.level 1!\"\n        end\n      end\n\n      context \"when this limit is reached\" do\n        it \"should annoyance adjust a given text by replacing the text with duplicated annoyance messages\" do\n          meter = Annoyance::Meter.new(2)\n          meter.annoyance_adjusted(\"text.\", 4).should == \"level 2!level 2!level 2!\"\n        end\n      end\n    end\n  end\nend"
  },
  {
    "path": "components/annoyance/spec/spec_helper.rb",
    "content": "#needed for newer versions of rspec."
  },
  {
    "path": "components/annoyance/test.sh",
    "content": "#!/bin/bash\n\nexit_code=0\n\necho \"*** Running annoyance gem specs\"\nbundle install  --jobs=3 --retry=3 | grep Installing\nbundle exec rspec spec\nexit_code+=$?\n\nexit $exit_code\n\n"
  },
  {
    "path": "components/email_signup/.gitignore",
    "content": ".bundle/\nlog/*.log\npkg/\nspec/dummy/db/*.sqlite3\nspec/dummy/log/*.log\nspec/dummy/tmp/\nspec/dummy/.sass-cache\n"
  },
  {
    "path": "components/email_signup/.rspec",
    "content": "--color\n"
  },
  {
    "path": "components/email_signup/.ruby-gemset",
    "content": "tnbtes\n"
  },
  {
    "path": "components/email_signup/.ruby-version",
    "content": "2.1.0\n"
  },
  {
    "path": "components/email_signup/Gemfile",
    "content": "source \"https://rubygems.org\"\n\ngemspec\n"
  },
  {
    "path": "components/email_signup/MIT-LICENSE",
    "content": "Copyright 2013 YOURNAME\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": "components/email_signup/README.rdoc",
    "content": "= EmailSignup\n\nThis project rocks and uses MIT-LICENSE."
  },
  {
    "path": "components/email_signup/Rakefile",
    "content": "#!/usr/bin/env rake\nbegin\n  require 'bundler/setup'\nrescue LoadError\n  puts 'You must `gem install bundler` and `bundle install` to run rake tasks'\nend\nbegin\n  require 'rdoc/task'\nrescue LoadError\n  require 'rdoc/rdoc'\n  require 'rake/rdoctask'\n  RDoc::Task = Rake::RDocTask\nend\n\nRDoc::Task.new(:rdoc) do |rdoc|\n  rdoc.rdoc_dir = 'rdoc'\n  rdoc.title    = 'EmailSignup'\n  rdoc.options << '--line-numbers'\n  rdoc.rdoc_files.include('README.rdoc')\n  rdoc.rdoc_files.include('lib/**/*.rb')\nend\n\nAPP_RAKEFILE = File.expand_path(\"../spec/dummy/Rakefile\", __FILE__)\nload 'rails/tasks/engine.rake'\n\n\n\nBundler::GemHelper.install_tasks\n\n"
  },
  {
    "path": "components/email_signup/app/models/email_signup/entry.rb",
    "content": "module EmailSignup\n  class Entry < ActiveRecord::Base\n    # attr_accessible :email, :tries\n    validates :email, presence: true, uniqueness: true\n  end\nend"
  },
  {
    "path": "components/email_signup/app/models/email_signup/entry_manager.rb",
    "content": "module EmailSignup\n  class EntryManager\n    def create(email)\n      return if find_by_email(email)\n      EmailSignup::Entry.create email: email\n    end\n\n    def find_by_email(email)\n      EmailSignup::Entry.find_by_email email\n    end\n  end\nend"
  },
  {
    "path": "components/email_signup/config/routes.rb",
    "content": "EmailSignup::Engine.routes.draw do\nend\n"
  },
  {
    "path": "components/email_signup/db/migrate/20130331124429_create_news_signup_entry.rb",
    "content": "class CreateNewsSignupEntry < ActiveRecord::Migration\n  def change\n    create_table \"news_signup_entries\", force: true do |t|\n      t.string \"email\"\n      t.datetime \"created_at\", null: false\n      t.datetime \"updated_at\", null: false\n      t.integer \"tries\", default: 0\n    end\n  end\nend\n"
  },
  {
    "path": "components/email_signup/db/migrate/20130331134505_rename_news_signup_etnries_to_email_signup_entries.rb",
    "content": "class RenameNewsSignupEtnriesToEmailSignupEntries < ActiveRecord::Migration\n  def change\n    rename_table :news_signup_entries, :email_signup_entries\n  end\nend\n"
  },
  {
    "path": "components/email_signup/db/migrate/20130403220851_remove_tries_from_email_signup_entry.rb",
    "content": "class RemoveTriesFromEmailSignupEntry < ActiveRecord::Migration\n  def change\n    remove_column :email_signup_entries, :tries\n  end\nend\n"
  },
  {
    "path": "components/email_signup/email_signup.gemspec",
    "content": "$:.push File.expand_path(\"../lib\", __FILE__)\n\n# Maintain your gem's version:\nrequire \"email_signup/version\"\n\n# Describe your gem and declare its dependencies:\nGem::Specification.new do |s|\n  s.name        = \"email_signup\"\n  s.version     = EmailSignup::VERSION\n  s.authors     = [\"Stephan Hagemann\"]\n  s.email       = [\"stephan.hagemann@gmail.com\"]\n  s.summary     = \"The engine that is doing signup\"\n  s.description = \"The engine that is doing signup\"\n\n  s.files = Dir[\"{app,config,db,lib}/**/*\"] + [\"MIT-LICENSE\", \"Rakefile\", \"README.rdoc\"]\n\n  s.add_dependency \"rails\", \"4.1.8\"\n\n  s.add_development_dependency \"rspec-rails\", \"3.1.0\"\n  s.add_development_dependency \"shoulda-matchers\", \"2.7.0\"\n  s.add_development_dependency \"sqlite3\", \"1.3.9\"\nend\n"
  },
  {
    "path": "components/email_signup/lib/email_signup/engine.rb",
    "content": "module EmailSignup\n  class Engine < ::Rails::Engine\n    isolate_namespace EmailSignup\n\n    initializer :append_migrations do |app|\n      unless app.root.to_s.match root.to_s + File::SEPARATOR\n        config.paths[\"db/migrate\"].expanded.each do |path|\n          app.config.paths[\"db/migrate\"] << path\n        end\n      end\n    end\n  end\nend\n"
  },
  {
    "path": "components/email_signup/lib/email_signup/version.rb",
    "content": "module EmailSignup\n  VERSION = \"0.0.1\"\nend\n"
  },
  {
    "path": "components/email_signup/lib/email_signup.rb",
    "content": "require \"email_signup/engine\"\n\nmodule EmailSignup\nend\n"
  },
  {
    "path": "components/email_signup/lib/tasks/news_signup_tasks.rake",
    "content": "# desc \"Explaining what the task does\"\n# task :email_signup do\n#   # Task goes here\n# end\n"
  },
  {
    "path": "components/email_signup/script/rails",
    "content": "#!/usr/bin/env ruby\n# This command will automatically be run when you run \"rails\" with Rails 3 gems installed from the root of your application.\n\nENGINE_ROOT = File.expand_path('../..', __FILE__)\nENGINE_PATH = File.expand_path('../../lib/email_signup/engine', __FILE__)\n\nrequire 'rails/all'\nrequire 'rails/engine/commands'\n"
  },
  {
    "path": "components/email_signup/spec/dummy/README.rdoc",
    "content": "== Welcome to Rails\n\nRails is a web-application framework that includes everything needed to create\ndatabase-backed web applications according to the Model-View-Control pattern.\n\nThis pattern splits the view (also called the presentation) into \"dumb\"\ntemplates that are primarily responsible for inserting pre-built data in between\nHTML tags. The model contains the \"smart\" domain objects (such as Account,\nProduct, Person, Post) that holds all the business logic and knows how to\npersist themselves to a database. The controller handles the incoming requests\n(such as Save New Account, Update Product, Show Post) by manipulating the model\nand directing data to the view.\n\nIn Rails, the model is handled by what's called an object-relational mapping\nlayer entitled Active Record. This layer allows you to present the data from\ndatabase rows as objects and embellish these data objects with business logic\nmethods. You can read more about Active Record in\nlink:files/vendor/rails/activerecord/README.html.\n\nThe controller and view are handled by the Action Pack, which handles both\nlayers by its two parts: Action View and Action Controller. These two layers\nare bundled in a single package due to their heavy interdependence. This is\nunlike the relationship between the Active Record and Action Pack that is much\nmore separate. Each of these packages can be used independently outside of\nRails. You can read more about Action Pack in\nlink:files/vendor/rails/actionpack/README.html.\n\n\n== Getting Started\n\n1. At the command prompt, create a new Rails application:\n       <tt>rails new myapp</tt> (where <tt>myapp</tt> is the application name)\n\n2. Change directory to <tt>myapp</tt> and start the web server:\n       <tt>cd myapp; rails server</tt> (run with --help for options)\n\n3. Go to http://localhost:3000/ and you'll see:\n       \"Welcome aboard: You're riding Ruby on Rails!\"\n\n4. Follow the guidelines to start developing your application. You can find\nthe following resources handy:\n\n* The Getting Started Guide: http://guides.rubyonrails.org/getting_started.html\n* Ruby on Rails Tutorial Book: http://www.railstutorial.org/\n\n\n== Debugging Rails\n\nSometimes your application goes wrong. Fortunately there are a lot of tools that\nwill help you debug it and get it back on the rails.\n\nFirst area to check is the application log files. Have \"tail -f\" commands\nrunning on the server.log and development.log. Rails will automatically display\ndebugging and runtime information to these files. Debugging info will also be\nshown in the browser on requests from 127.0.0.1.\n\nYou can also log your own messages directly into the log file from your code\nusing the Ruby logger class from inside your controllers. Example:\n\n  class WeblogController < ActionController::Base\n    def destroy\n      @weblog = Weblog.find(params[:id])\n      @weblog.destroy\n      logger.info(\"#{Time.now} Destroyed Weblog ID ##{@weblog.id}!\")\n    end\n  end\n\nThe result will be a message in your log file along the lines of:\n\n  Mon Oct 08 14:22:29 +1000 2007 Destroyed Weblog ID #1!\n\nMore information on how to use the logger is at http://www.ruby-doc.org/core/\n\nAlso, Ruby documentation can be found at http://www.ruby-lang.org/. There are\nseveral books available online as well:\n\n* Programming Ruby: http://www.ruby-doc.org/docs/ProgrammingRuby/ (Pickaxe)\n* Learn to Program: http://pine.fm/LearnToProgram/ (a beginners guide)\n\nThese two books will bring you up to speed on the Ruby language and also on\nprogramming in general.\n\n\n== Debugger\n\nDebugger support is available through the debugger command when you start your\nMongrel or WEBrick server with --debugger. This means that you can break out of\nexecution at any point in the code, investigate and change the model, and then,\nresume execution! You need to install ruby-debug to run the server in debugging\nmode. With gems, use <tt>sudo gem install ruby-debug</tt>. Example:\n\n  class WeblogController < ActionController::Base\n    def index\n      @posts = Post.all\n      debugger\n    end\n  end\n\nSo the controller will accept the action, run the first line, then present you\nwith a IRB prompt in the server window. Here you can do things like:\n\n  >> @posts.inspect\n  => \"[#<Post:0x14a6be8\n          @attributes={\"title\"=>nil, \"body\"=>nil, \"id\"=>\"1\"}>,\n       #<Post:0x14a6620\n          @attributes={\"title\"=>\"Rails\", \"body\"=>\"Only ten..\", \"id\"=>\"2\"}>]\"\n  >> @posts.first.title = \"hello from a debugger\"\n  => \"hello from a debugger\"\n\n...and even better, you can examine how your runtime objects actually work:\n\n  >> f = @posts.first\n  => #<Post:0x13630c4 @attributes={\"title\"=>nil, \"body\"=>nil, \"id\"=>\"1\"}>\n  >> f.\n  Display all 152 possibilities? (y or n)\n\nFinally, when you're ready to resume execution, you can enter \"cont\".\n\n\n== Console\n\nThe console is a Ruby shell, which allows you to interact with your\napplication's domain model. Here you'll have all parts of the application\nconfigured, just like it is when the application is running. You can inspect\ndomain models, change values, and save to the database. Starting the script\nwithout arguments will launch it in the development environment.\n\nTo start the console, run <tt>rails console</tt> from the application\ndirectory.\n\nOptions:\n\n* Passing the <tt>-s, --sandbox</tt> argument will rollback any modifications\n  made to the database.\n* Passing an environment name as an argument will load the corresponding\n  environment. Example: <tt>rails console production</tt>.\n\nTo reload your controllers and models after launching the console run\n<tt>reload!</tt>\n\nMore information about irb can be found at:\nlink:http://www.rubycentral.org/pickaxe/irb.html\n\n\n== dbconsole\n\nYou can go to the command line of your database directly through <tt>rails\ndbconsole</tt>. You would be connected to the database with the credentials\ndefined in database.yml. Starting the script without arguments will connect you\nto the development database. Passing an argument will connect you to a different\ndatabase, like <tt>rails dbconsole production</tt>. Currently works for MySQL,\nPostgreSQL and SQLite 3.\n\n== Description of Contents\n\nThe default directory structure of a generated Ruby on Rails application:\n\n  |-- app\n  |   |-- assets\n  |   |   |-- images\n  |   |   |-- javascripts\n  |   |   `-- stylesheets\n  |   |-- controllers\n  |   |-- helpers\n  |   |-- mailers\n  |   |-- models\n  |   `-- views\n  |       `-- layouts\n  |-- config\n  |   |-- environments\n  |   |-- initializers\n  |   `-- locales\n  |-- db\n  |-- doc\n  |-- lib\n  |   |-- assets\n  |   `-- tasks\n  |-- log\n  |-- public\n  |-- script\n  |-- test\n  |   |-- fixtures\n  |   |-- functional\n  |   |-- integration\n  |   |-- performance\n  |   `-- unit\n  |-- tmp\n  |   `-- cache\n  |       `-- assets\n  `-- vendor\n      |-- assets\n      |   |-- javascripts\n      |   `-- stylesheets\n      `-- plugins\n\napp\n  Holds all the code that's specific to this particular application.\n\napp/assets\n  Contains subdirectories for images, stylesheets, and JavaScript files.\n\napp/controllers\n  Holds controllers that should be named like weblogs_controller.rb for\n  automated URL mapping. All controllers should descend from\n  ApplicationController which itself descends from ActionController::Base.\n\napp/models\n  Holds models that should be named like post.rb. Models descend from\n  ActiveRecord::Base by default.\n\napp/views\n  Holds the template files for the view that should be named like\n  weblogs/index.html.erb for the WeblogsController#index action. All views use\n  eRuby syntax by default.\n\napp/views/layouts\n  Holds the template files for layouts to be used with views. This models the\n  common header/footer method of wrapping views. In your views, define a layout\n  using the <tt>layout :default</tt> and create a file named default.html.erb.\n  Inside default.html.erb, call <% yield %> to render the view using this\n  layout.\n\napp/helpers\n  Holds view helpers that should be named like weblogs_helper.rb. These are\n  generated for you automatically when using generators for controllers.\n  Helpers can be used to wrap functionality for your views into methods.\n\nconfig\n  Configuration files for the Rails environment, the routing map, the database,\n  and other dependencies.\n\ndb\n  Contains the database schema in schema.rb. db/migrate contains all the\n  sequence of Migrations for your schema.\n\ndoc\n  This directory is where your application documentation will be stored when\n  generated using <tt>rake doc:app</tt>\n\nlib\n  Application specific libraries. Basically, any kind of custom code that\n  doesn't belong under controllers, models, or helpers. This directory is in\n  the load path.\n\npublic\n  The directory available for the web server. Also contains the dispatchers and the\n  default HTML files. This should be set as the DOCUMENT_ROOT of your web\n  server.\n\nscript\n  Helper scripts for automation and generation.\n\ntest\n  Unit and functional tests along with fixtures. When using the rails generate\n  command, template test files will be generated for you and placed in this\n  directory.\n\nvendor\n  External libraries that the application depends on. Also includes the plugins\n  subdirectory. If the app has frozen rails, those gems also go here, under\n  vendor/rails/. This directory is in the load path.\n"
  },
  {
    "path": "components/email_signup/spec/dummy/Rakefile",
    "content": "#!/usr/bin/env rake\n# Add your own tasks in files placed in lib/tasks ending in .rake,\n# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.\n\nrequire File.expand_path('../config/application', __FILE__)\n\nDummy::Application.load_tasks\n"
  },
  {
    "path": "components/email_signup/spec/dummy/app/assets/javascripts/application.js",
    "content": "// This is a manifest file that'll be compiled into application.js, which will include all the files\n// listed below.\n//\n// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,\n// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.\n//\n// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the\n// the compiled file.\n//\n// WARNING: THE FIRST BLANK LINE MARKS THE END OF WHAT'S TO BE PROCESSED, ANY BLANK LINE SHOULD\n// GO AFTER THE REQUIRES BELOW.\n//\n//= require jquery\n//= require jquery_ujs\n//= require_tree .\n"
  },
  {
    "path": "components/email_signup/spec/dummy/app/assets/stylesheets/application.css",
    "content": "/*\n * This is a manifest file that'll be compiled into application.css, which will include all the files\n * listed below.\n *\n * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,\n * or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path.\n *\n * You're free to add application-wide styles to this file and they'll appear at the top of the\n * compiled file, but it's generally better to create a new file per style scope.\n *\n *= require_self\n *= require_tree .\n */\n"
  },
  {
    "path": "components/email_signup/spec/dummy/app/controllers/application_controller.rb",
    "content": "class ApplicationController < ActionController::Base\n  protect_from_forgery\nend\n"
  },
  {
    "path": "components/email_signup/spec/dummy/app/helpers/application_helper.rb",
    "content": "module ApplicationHelper\nend\n"
  },
  {
    "path": "components/email_signup/spec/dummy/app/mailers/.gitkeep",
    "content": ""
  },
  {
    "path": "components/email_signup/spec/dummy/app/models/.gitkeep",
    "content": ""
  },
  {
    "path": "components/email_signup/spec/dummy/app/views/layouts/application.html.erb",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>Dummy</title>\n  <%= stylesheet_link_tag    \"application\", :media => \"all\" %>\n  <%= javascript_include_tag \"application\" %>\n  <%= csrf_meta_tags %>\n</head>\n<body>\n\n<%= yield %>\n\n</body>\n</html>\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/application.rb",
    "content": "require File.expand_path('../boot', __FILE__)\n\n# Pick the frameworks you want:\nrequire \"active_record/railtie\"\nrequire \"action_controller/railtie\"\nrequire \"action_mailer/railtie\"\n# require \"active_resource/railtie\"\nrequire \"sprockets/railtie\"\n# require \"rails/test_unit/railtie\"\n\nBundler.require(*Rails.groups)\nrequire \"email_signup\"\n\nmodule Dummy\n  class Application < Rails::Application\n    # Settings in config/environments/* take precedence over those specified here.\n    # Application configuration should go into files in config/initializers\n    # -- all .rb files in that directory are automatically loaded.\n\n    # Custom directories with classes and modules you want to be autoloadable.\n    # config.autoload_paths += %W(#{config.root}/extras)\n\n    # Only load the plugins named here, in the order given (default is alphabetical).\n    # :all can be used as a placeholder for all plugins not explicitly named.\n    # config.plugins = [ :exception_notification, :ssl_requirement, :all ]\n\n    # Activate observers that should always be running.\n    # config.active_record.observers = :cacher, :garbage_collector, :forum_observer\n\n    # Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.\n    # Run \"rake -D time\" for a list of tasks for finding time zone names. Default is UTC.\n    # config.time_zone = 'Central Time (US & Canada)'\n\n    # The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.\n    # config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]\n    # config.i18n.default_locale = :de\n\n    # Configure the default encoding used in templates for Ruby 1.9.\n    config.encoding = \"utf-8\"\n\n    # Configure sensitive parameters which will be filtered from the log file.\n    config.filter_parameters += [:password]\n\n    # Enable escaping HTML in JSON.\n    config.active_support.escape_html_entities_in_json = true\n\n    # Use SQL instead of Active Record's schema dumper when creating the database.\n    # This is necessary if your schema can't be completely dumped by the schema dumper,\n    # like if you have constraints or database-specific column types\n    # config.active_record.schema_format = :sql\n\n    # Enable the asset pipeline\n    config.assets.enabled = true\n\n    # Version of your assets, change this if you want to expire all your assets\n    config.assets.version = '1.0'\n    \n    config.secret_key_base = \"some super secret\"\n  end\nend\n\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/boot.rb",
    "content": "require 'rubygems'\ngemfile = File.expand_path('../../../../Gemfile', __FILE__)\n\nif File.exist?(gemfile)\n  ENV['BUNDLE_GEMFILE'] = gemfile\n  require 'bundler'\n  Bundler.setup\nend\n\n$:.unshift File.expand_path('../../../../lib', __FILE__)"
  },
  {
    "path": "components/email_signup/spec/dummy/config/database.yml",
    "content": "development:\n  adapter: sqlite3\n  database: db/development.sqlite3\n  pool: 5\n  timeout: 5000\n\ntest:\n  adapter: sqlite3\n  database: db/test.sqlite3\n  pool: 5\n  timeout: 5000\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/environment.rb",
    "content": "# Load the rails application\nrequire File.expand_path('../application', __FILE__)\n\n# Initialize the rails application\nDummy::Application.initialize!\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/environments/development.rb",
    "content": "Dummy::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # In the development environment your application's code is reloaded on\n  # every request. This slows down response time but is perfect for development\n  # since you don't have to restart the web server when you make code changes.\n  config.cache_classes = false\n\n  # Show full error reports and disable caching\n  config.consider_all_requests_local       = true\n  config.action_controller.perform_caching = false\n\n  # Don't care if the mailer can't send\n  config.action_mailer.raise_delivery_errors = false\n\n  # Print deprecation notices to the Rails logger\n  config.active_support.deprecation = :log\n\n  # Only use best-standards-support built into browsers\n  config.action_dispatch.best_standards_support = :builtin\n\n  # Do not compress assets\n  config.assets.compress = false\n\n  # Expands the lines which load the assets\n  config.assets.debug = true\n\n  config.eager_load = false\nend\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/environments/production.rb",
    "content": "Dummy::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # Code is not reloaded between requests\n  config.cache_classes = true\n\n  # Full error reports are disabled and caching is turned on\n  config.consider_all_requests_local       = false\n  config.action_controller.perform_caching = true\n\n  # Disable Rails's static asset server (Apache or nginx will already do this)\n  config.serve_static_assets = false\n\n  # Compress JavaScripts and CSS\n  config.assets.compress = true\n\n  # Don't fallback to assets pipeline if a precompiled asset is missed\n  config.assets.compile = false\n\n  # Generate digests for assets URLs\n  config.assets.digest = true\n\n  # Defaults to nil and saved in location specified by config.assets.prefix\n  # config.assets.manifest = YOUR_PATH\n\n  # Specifies the header that your server uses for sending files\n  # config.action_dispatch.x_sendfile_header = \"X-Sendfile\" # for apache\n  # config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for nginx\n\n  # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.\n  # config.force_ssl = true\n\n  # See everything in the log (default is :info)\n  # config.log_level = :debug\n\n  # Prepend all log lines with the following tags\n  # config.log_tags = [ :subdomain, :uuid ]\n\n  # Use a different logger for distributed setups\n  # config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new)\n\n  # Use a different cache store in production\n  # config.cache_store = :mem_cache_store\n\n  # Enable serving of images, stylesheets, and JavaScripts from an asset server\n  # config.action_controller.asset_host = \"http://assets.example.com\"\n\n  # Precompile additional assets (application.js, application.css, and all non-JS/CSS are already added)\n  # config.assets.precompile += %w( search.js )\n\n  # Disable delivery errors, bad email addresses will be ignored\n  # config.action_mailer.raise_delivery_errors = false\n\n  # Enable threaded mode\n  # config.threadsafe!\n\n  # Enable locale fallbacks for I18n (makes lookups for any locale fall back to\n  # the I18n.default_locale when a translation can not be found)\n  config.i18n.fallbacks = true\n\n  # Send deprecation notices to registered listeners\n  config.active_support.deprecation = :notify\n\n  config.eager_load = true\nend\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/environments/test.rb",
    "content": "Dummy::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # The test environment is used exclusively to run your application's\n  # test suite. You never need to work with it otherwise. Remember that\n  # your test database is \"scratch space\" for the test suite and is wiped\n  # and recreated between test runs. Don't rely on the data there!\n  config.cache_classes = true\n\n  # Configure static asset server for tests with Cache-Control for performance\n  config.serve_static_assets = true\n  config.static_cache_control = \"public, max-age=3600\"\n\n  # Show full error reports and disable caching\n  config.consider_all_requests_local       = true\n  config.action_controller.perform_caching = false\n\n  # Raise exceptions instead of rendering exception templates\n  config.action_dispatch.show_exceptions = false\n\n  # Disable request forgery protection in test environment\n  config.action_controller.allow_forgery_protection    = false\n\n  # Tell Action Mailer not to deliver emails to the real world.\n  # The :test delivery method accumulates sent emails in the\n  # ActionMailer::Base.deliveries array.\n  config.action_mailer.delivery_method = :test\n\n  # Print deprecation notices to the stderr\n  config.active_support.deprecation = :stderr\n\n  config.eager_load = false\nend\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/initializers/backtrace_silencers.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces.\n# Rails.backtrace_cleaner.add_silencer { |line| line =~ /my_noisy_library/ }\n\n# You can also remove all the silencers if you're trying to debug a problem that might stem from framework code.\n# Rails.backtrace_cleaner.remove_silencers!\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/initializers/inflections.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Add new inflection rules using the following format\n# (all these examples are active by default):\n# ActiveSupport::Inflector.inflections do |inflect|\n#   inflect.plural /^(ox)$/i, '\\1en'\n#   inflect.singular /^(ox)en/i, '\\1'\n#   inflect.irregular 'person', 'people'\n#   inflect.uncountable %w( fish sheep )\n# end\n#\n# These inflection rules are supported but not enabled by default:\n# ActiveSupport::Inflector.inflections do |inflect|\n#   inflect.acronym 'RESTful'\n# end\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/initializers/mime_types.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Add new mime types for use in respond_to blocks:\n# Mime::Type.register \"text/richtext\", :rtf\n# Mime::Type.register_alias \"text/html\", :iphone\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/initializers/secret_token.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Your secret key for verifying the integrity of signed cookies.\n# If you change this key, all old signed cookies will become invalid!\n# Make sure the secret is at least 30 characters and all random,\n# no regular words or you'll be exposed to dictionary attacks.\nDummy::Application.config.secret_token = 'b0423e3c871d076e94ed32c71a31a7ea3885fe8eb7910d0013f0213f3f30cd84395366f1d0bc5c995ce3d77a1cb4e6d16306380b4a95e1216e9b4ea66b8fb76d'\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/initializers/session_store.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\nDummy::Application.config.session_store :cookie_store, key: '_dummy_session'\n\n# Use the database for sessions instead of the cookie-based default,\n# which shouldn't be used to store highly confidential information\n# (create the session table with \"rails generate session_migration\")\n# Dummy::Application.config.session_store :active_record_store\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/initializers/wrap_parameters.rb",
    "content": "# Be sure to restart your server when you modify this file.\n#\n# This file contains settings for ActionController::ParamsWrapper which\n# is enabled by default.\n\n# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.\nActiveSupport.on_load(:action_controller) do\n  wrap_parameters format: [:json]\nend\n\n# Disable root element in JSON by default.\nActiveSupport.on_load(:active_record) do\n  self.include_root_in_json = false\nend\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/locales/en.yml",
    "content": "# Sample localization file for English. Add more files in this directory for other locales.\n# See https://github.com/svenfuchs/rails-i18n/tree/master/rails%2Flocale for starting points.\n\nen:\n  hello: \"Hello world\"\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config/routes.rb",
    "content": "Rails.application.routes.draw do\n\n  mount EmailSignup::Engine => \"/email_signup\"\nend\n"
  },
  {
    "path": "components/email_signup/spec/dummy/config.ru",
    "content": "# This file is used by Rack-based servers to start the application.\n\nrequire ::File.expand_path('../config/environment',  __FILE__)\nrun Dummy::Application\n"
  },
  {
    "path": "components/email_signup/spec/dummy/db/schema.rb",
    "content": "# encoding: UTF-8\n# This file is auto-generated from the current state of the database. Instead\n# of editing this file, please use the migrations feature of Active Record to\n# incrementally modify your database, and then regenerate this schema definition.\n#\n# Note that this schema.rb definition is the authoritative source for your\n# database schema. If you need to create the application database on another\n# system, you should be using db:schema:load, not running all the migrations\n# from scratch. The latter is a flawed and unsustainable approach (the more migrations\n# you'll amass, the slower it'll run and the greater likelihood for issues).\n#\n# It's strongly recommended that you check this file into your version control system.\n\nActiveRecord::Schema.define(version: 20130403220851) do\n\n  create_table \"email_signup_entries\", force: true do |t|\n    t.string   \"email\"\n    t.datetime \"created_at\", null: false\n    t.datetime \"updated_at\", null: false\n  end\n\nend\n"
  },
  {
    "path": "components/email_signup/spec/dummy/lib/assets/.gitkeep",
    "content": ""
  },
  {
    "path": "components/email_signup/spec/dummy/log/.gitkeep",
    "content": ""
  },
  {
    "path": "components/email_signup/spec/dummy/public/404.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>The page you were looking for doesn't exist (404)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/404.html -->\n  <div class=\"dialog\">\n    <h1>The page you were looking for doesn't exist.</h1>\n    <p>You may have mistyped the address or the page may have moved.</p>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "components/email_signup/spec/dummy/public/422.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>The change you wanted was rejected (422)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/422.html -->\n  <div class=\"dialog\">\n    <h1>The change you wanted was rejected.</h1>\n    <p>Maybe you tried to change something you didn't have access to.</p>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "components/email_signup/spec/dummy/public/500.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>We're sorry, but something went wrong (500)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/500.html -->\n  <div class=\"dialog\">\n    <h1>We're sorry, but something went wrong.</h1>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "components/email_signup/spec/dummy/script/rails",
    "content": "#!/usr/bin/env ruby\n# This command will automatically be run when you run \"rails\" with Rails 3 gems installed from the root of your application.\n\nAPP_PATH = File.expand_path('../../config/application',  __FILE__)\nrequire File.expand_path('../../config/boot',  __FILE__)\nrequire 'rails/commands'\n"
  },
  {
    "path": "components/email_signup/spec/models/email_signup/entry_manager_spec.rb",
    "content": "require \"spec_helper\"\n\nmodule EmailSignup\n  describe EmailSignup::EntryManager do\n    before do\n      Entry.delete_all\n    end\n    \n    describe \"#create\" do\n      it \"creates an entry\" do\n        expect {\n          subject.create \"some_email@example.com\"\n        }.to change(Entry, :count).from(0).to(1)\n      end\n\n      it \"does not create an entry with the same email address twice\" do\n        subject.create \"some_email@example.com\"\n        expect {\n          subject.create(\"some_email@example.com\").should == nil\n        }.to_not change(Entry, :count)\n      end\n    end\n\n    describe \"#find_by_email\" do\n      before do\n        @entry = Entry.create! email: \"some_email@example.com\"\n      end\n\n      it \"returns an entry iff the correct email is used\" do\n        subject.find_by_email(\"some_email@example.com\").should == @entry\n        subject.find_by_email(\"some_other_email@example.com\").should == nil\n      end\n    end\n  end\nend"
  },
  {
    "path": "components/email_signup/spec/models/email_signup/entry_spec.rb",
    "content": "require \"spec_helper\"\n\nmodule EmailSignup\n  describe EmailSignup::Entry do\n    it { should validate_presence_of :email }\n    it { should validate_uniqueness_of :email }\n  end\nend"
  },
  {
    "path": "components/email_signup/spec/spec_helper.rb",
    "content": "# This file is copied to spec/ when you run 'rails generate rspec:install'\nENV[\"RAILS_ENV\"] ||= 'test'\nrequire File.expand_path(\"../dummy/config/environment\", __FILE__)\nrequire 'rspec/rails'\nrequire 'rspec/autorun'\nrequire 'shoulda-matchers'\n\nDir[EmailSignup::Engine.root.join(\"spec/support/**/*.rb\")].each {|f| require f}\n\nRSpec.configure do |config|\n  config.use_transactional_fixtures = true\n  config.infer_base_class_for_anonymous_controllers = false\n  config.order = \"random\"\nend\n"
  },
  {
    "path": "components/email_signup/test.sh",
    "content": "#!/bin/bash\n\nexit_code=0\n\necho \"*** Running email signup engine specs\"\nbundle install  --jobs=3 --retry=3 | grep Installing\nbundle exec rake db:create db:migrate #don't remove this line. If only run in test our schema.rb doesn't include required engine's migrations\nRAILS_ENV=test bundle exec rake db:create db:migrate\nbundle exec rspec spec/models\nexit_code+=$?\n\nexit $exit_code"
  },
  {
    "path": "components/event_counter/.gitignore",
    "content": ".bundle/\nlog/*.log\npkg/\nspec/dummy/db/*.sqlite3\nspec/dummy/log/*.log\nspec/dummy/tmp/\nspec/dummy/.sass-cache\n"
  },
  {
    "path": "components/event_counter/.rspec",
    "content": "--color\n"
  },
  {
    "path": "components/event_counter/.ruby-gemset",
    "content": "tnbtec\n"
  },
  {
    "path": "components/event_counter/.ruby-version",
    "content": "2.1.0\n"
  },
  {
    "path": "components/event_counter/Gemfile",
    "content": "source \"https://rubygems.org\"\ngemspec\n\ngem \"rspec-rails\"\ngem \"shoulda-matchers\"\ngem \"sqlite3\"\n\n"
  },
  {
    "path": "components/event_counter/MIT-LICENSE",
    "content": "Copyright 2013 YOURNAME\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": "components/event_counter/README.rdoc",
    "content": "= EventCounter\n\nThis project rocks and uses MIT-LICENSE."
  },
  {
    "path": "components/event_counter/Rakefile",
    "content": "#!/usr/bin/env rake\nbegin\n  require 'bundler/setup'\nrescue LoadError\n  puts 'You must `gem install bundler` and `bundle install` to run rake tasks'\nend\nbegin\n  require 'rdoc/task'\nrescue LoadError\n  require 'rdoc/rdoc'\n  require 'rake/rdoctask'\n  RDoc::Task = Rake::RDocTask\nend\n\nRDoc::Task.new(:rdoc) do |rdoc|\n  rdoc.rdoc_dir = 'rdoc'\n  rdoc.title    = 'EventCounter'\n  rdoc.options << '--line-numbers'\n  rdoc.rdoc_files.include('README.rdoc')\n  rdoc.rdoc_files.include('lib/**/*.rb')\nend\n\nAPP_RAKEFILE = File.expand_path(\"../spec/dummy/Rakefile\", __FILE__)\nload 'rails/tasks/engine.rake'\n\n\n\nBundler::GemHelper.install_tasks\n\n"
  },
  {
    "path": "components/event_counter/app/models/event_counter/logger.rb",
    "content": "module EventCounter\n  class Logger\n    def log(object_identifier, event_identifier)\n      counter = Count.where(object_identifier: object_identifier, event_identifier: event_identifier).try :first\n      if counter.present?\n        counter.update_attribute(:count, counter.count + 1)\n      else\n        counter = Count.create do |count|\n          count.object_identifier = object_identifier\n          count.event_identifier = event_identifier\n          count.count = 1\n        end\n      end\n      counter.count\n    end\n\n    private\n\n    class Count < ActiveRecord::Base\n    end\n  end\nend"
  },
  {
    "path": "components/event_counter/config/routes.rb",
    "content": "EventCounter::Engine.routes.draw do\nend\n"
  },
  {
    "path": "components/event_counter/db/migrate/20130403021547_create_event_counter_count.rb",
    "content": "class CreateEventCounterCount < ActiveRecord::Migration\n  def change\n    create_table :event_counter_counts do |t|\n      t.string \"object_identifier\"\n      t.string \"event_identifier\"\n      t.integer \"count\", default: 0\n    end\n  end\nend\n"
  },
  {
    "path": "components/event_counter/event_counter.gemspec",
    "content": "$:.push File.expand_path(\"../lib\", __FILE__)\n\n# Maintain your gem's version:\nrequire \"event_counter/version\"\n\n# Describe your gem and declare its dependencies:\nGem::Specification.new do |s|\n  s.name        = \"event_counter\"\n  s.version     = EventCounter::VERSION\n  s.authors     = [\"Stephan Hagemann\"]\n  s.email       = [\"stephan@pivotallabs.com\"]\n  s.homepage    = \"https://github.com/shageman/event_counter\"\n  s.summary     = \"Rails engine to count the occurences of events on objects.\"\n  s.description = \"This engine is part of a rails-architcture-sample app, which you can find at https://github.com/shageman/the_next_big_thing\"\n\n  s.files = Dir[\"{app,config,db,lib}/**/*\"] + [\"MIT-LICENSE\", \"Rakefile\", \"README.rdoc\"]\n\n  s.add_dependency \"rails\", \"4.1.8\"\n\n  s.add_development_dependency \"rspec-rails\", \"3.1.0\"\n  s.add_development_dependency \"shoulda-matchers\", \"1.4.2\"\n  s.add_development_dependency \"sqlite3\", \"1.3.7\"\nend\n"
  },
  {
    "path": "components/event_counter/lib/event_counter/engine.rb",
    "content": "module EventCounter\n  class Engine < ::Rails::Engine\n    isolate_namespace EventCounter\n\n    initializer :append_migrations do |app|\n      unless app.root.to_s.match root.to_s + File::SEPARATOR\n        config.paths[\"db/migrate\"].expanded.each do |path|\n          app.config.paths[\"db/migrate\"] << path\n        end\n      end\n    end\n  end\nend\n"
  },
  {
    "path": "components/event_counter/lib/event_counter/test_helper.rb",
    "content": "require_relative \"../../spec/support/test_helper\""
  },
  {
    "path": "components/event_counter/lib/event_counter/version.rb",
    "content": "module EventCounter\n  VERSION = \"0.0.3\"\nend\n"
  },
  {
    "path": "components/event_counter/lib/event_counter.rb",
    "content": "require \"event_counter/engine\"\n\nmodule EventCounter\nend\n"
  },
  {
    "path": "components/event_counter/lib/tasks/event_counter_tasks.rake",
    "content": "# desc \"Explaining what the task does\"\n# task :event_counter do\n#   # Task goes here\n# end\n"
  },
  {
    "path": "components/event_counter/script/rails",
    "content": "#!/usr/bin/env ruby\n# This command will automatically be run when you run \"rails\" with Rails 3 gems installed from the root of your application.\n\nENGINE_ROOT = File.expand_path('../..', __FILE__)\nENGINE_PATH = File.expand_path('../../lib/event_counter/engine', __FILE__)\n\nrequire 'rails/all'\nrequire 'rails/engine/commands'\n"
  },
  {
    "path": "components/event_counter/spec/dummy/README.rdoc",
    "content": "== Welcome to Rails\n\nRails is a web-application framework that includes everything needed to create\ndatabase-backed web applications according to the Model-View-Control pattern.\n\nThis pattern splits the view (also called the presentation) into \"dumb\"\ntemplates that are primarily responsible for inserting pre-built data in between\nHTML tags. The model contains the \"smart\" domain objects (such as Account,\nProduct, Person, Post) that holds all the business logic and knows how to\npersist themselves to a database. The controller handles the incoming requests\n(such as Save New Account, Update Product, Show Post) by manipulating the model\nand directing data to the view.\n\nIn Rails, the model is handled by what's called an object-relational mapping\nlayer entitled Active Record. This layer allows you to present the data from\ndatabase rows as objects and embellish these data objects with business logic\nmethods. You can read more about Active Record in\nlink:files/vendor/rails/activerecord/README.html.\n\nThe controller and view are handled by the Action Pack, which handles both\nlayers by its two parts: Action View and Action Controller. These two layers\nare bundled in a single package due to their heavy interdependence. This is\nunlike the relationship between the Active Record and Action Pack that is much\nmore separate. Each of these packages can be used independently outside of\nRails. You can read more about Action Pack in\nlink:files/vendor/rails/actionpack/README.html.\n\n\n== Getting Started\n\n1. At the command prompt, create a new Rails application:\n       <tt>rails new myapp</tt> (where <tt>myapp</tt> is the application name)\n\n2. Change directory to <tt>myapp</tt> and start the web server:\n       <tt>cd myapp; rails server</tt> (run with --help for options)\n\n3. Go to http://localhost:3000/ and you'll see:\n       \"Welcome aboard: You're riding Ruby on Rails!\"\n\n4. Follow the guidelines to start developing your application. You can find\nthe following resources handy:\n\n* The Getting Started Guide: http://guides.rubyonrails.org/getting_started.html\n* Ruby on Rails Tutorial Book: http://www.railstutorial.org/\n\n\n== Debugging Rails\n\nSometimes your application goes wrong. Fortunately there are a lot of tools that\nwill help you debug it and get it back on the rails.\n\nFirst area to check is the application log files. Have \"tail -f\" commands\nrunning on the server.log and development.log. Rails will automatically display\ndebugging and runtime information to these files. Debugging info will also be\nshown in the browser on requests from 127.0.0.1.\n\nYou can also log your own messages directly into the log file from your code\nusing the Ruby logger class from inside your controllers. Example:\n\n  class WeblogController < ActionController::Base\n    def destroy\n      @weblog = Weblog.find(params[:id])\n      @weblog.destroy\n      logger.info(\"#{Time.now} Destroyed Weblog ID ##{@weblog.id}!\")\n    end\n  end\n\nThe result will be a message in your log file along the lines of:\n\n  Mon Oct 08 14:22:29 +1000 2007 Destroyed Weblog ID #1!\n\nMore information on how to use the logger is at http://www.ruby-doc.org/core/\n\nAlso, Ruby documentation can be found at http://www.ruby-lang.org/. There are\nseveral books available online as well:\n\n* Programming Ruby: http://www.ruby-doc.org/docs/ProgrammingRuby/ (Pickaxe)\n* Learn to Program: http://pine.fm/LearnToProgram/ (a beginners guide)\n\nThese two books will bring you up to speed on the Ruby language and also on\nprogramming in general.\n\n\n== Debugger\n\nDebugger support is available through the debugger command when you start your\nMongrel or WEBrick server with --debugger. This means that you can break out of\nexecution at any point in the code, investigate and change the model, and then,\nresume execution! You need to install ruby-debug to run the server in debugging\nmode. With gems, use <tt>sudo gem install ruby-debug</tt>. Example:\n\n  class WeblogController < ActionController::Base\n    def index\n      @posts = Post.all\n      debugger\n    end\n  end\n\nSo the controller will accept the action, run the first line, then present you\nwith a IRB prompt in the server window. Here you can do things like:\n\n  >> @posts.inspect\n  => \"[#<Post:0x14a6be8\n          @attributes={\"title\"=>nil, \"body\"=>nil, \"id\"=>\"1\"}>,\n       #<Post:0x14a6620\n          @attributes={\"title\"=>\"Rails\", \"body\"=>\"Only ten..\", \"id\"=>\"2\"}>]\"\n  >> @posts.first.title = \"hello from a debugger\"\n  => \"hello from a debugger\"\n\n...and even better, you can examine how your runtime objects actually work:\n\n  >> f = @posts.first\n  => #<Post:0x13630c4 @attributes={\"title\"=>nil, \"body\"=>nil, \"id\"=>\"1\"}>\n  >> f.\n  Display all 152 possibilities? (y or n)\n\nFinally, when you're ready to resume execution, you can enter \"cont\".\n\n\n== Console\n\nThe console is a Ruby shell, which allows you to interact with your\napplication's domain model. Here you'll have all parts of the application\nconfigured, just like it is when the application is running. You can inspect\ndomain models, change values, and save to the database. Starting the script\nwithout arguments will launch it in the development environment.\n\nTo start the console, run <tt>rails console</tt> from the application\ndirectory.\n\nOptions:\n\n* Passing the <tt>-s, --sandbox</tt> argument will rollback any modifications\n  made to the database.\n* Passing an environment name as an argument will load the corresponding\n  environment. Example: <tt>rails console production</tt>.\n\nTo reload your controllers and models after launching the console run\n<tt>reload!</tt>\n\nMore information about irb can be found at:\nlink:http://www.rubycentral.org/pickaxe/irb.html\n\n\n== dbconsole\n\nYou can go to the command line of your database directly through <tt>rails\ndbconsole</tt>. You would be connected to the database with the credentials\ndefined in database.yml. Starting the script without arguments will connect you\nto the development database. Passing an argument will connect you to a different\ndatabase, like <tt>rails dbconsole production</tt>. Currently works for MySQL,\nPostgreSQL and SQLite 3.\n\n== Description of Contents\n\nThe default directory structure of a generated Ruby on Rails application:\n\n  |-- app\n  |   |-- assets\n  |   |   |-- images\n  |   |   |-- javascripts\n  |   |   `-- stylesheets\n  |   |-- controllers\n  |   |-- helpers\n  |   |-- mailers\n  |   |-- models\n  |   `-- views\n  |       `-- layouts\n  |-- config\n  |   |-- environments\n  |   |-- initializers\n  |   `-- locales\n  |-- db\n  |-- doc\n  |-- lib\n  |   |-- assets\n  |   `-- tasks\n  |-- log\n  |-- public\n  |-- script\n  |-- test\n  |   |-- fixtures\n  |   |-- functional\n  |   |-- integration\n  |   |-- performance\n  |   `-- unit\n  |-- tmp\n  |   `-- cache\n  |       `-- assets\n  `-- vendor\n      |-- assets\n      |   |-- javascripts\n      |   `-- stylesheets\n      `-- plugins\n\napp\n  Holds all the code that's specific to this particular application.\n\napp/assets\n  Contains subdirectories for images, stylesheets, and JavaScript files.\n\napp/controllers\n  Holds controllers that should be named like weblogs_controller.rb for\n  automated URL mapping. All controllers should descend from\n  ApplicationController which itself descends from ActionController::Base.\n\napp/models\n  Holds models that should be named like post.rb. Models descend from\n  ActiveRecord::Base by default.\n\napp/views\n  Holds the template files for the view that should be named like\n  weblogs/index.html.erb for the WeblogsController#index action. All views use\n  eRuby syntax by default.\n\napp/views/layouts\n  Holds the template files for layouts to be used with views. This models the\n  common header/footer method of wrapping views. In your views, define a layout\n  using the <tt>layout :default</tt> and create a file named default.html.erb.\n  Inside default.html.erb, call <% yield %> to render the view using this\n  layout.\n\napp/helpers\n  Holds view helpers that should be named like weblogs_helper.rb. These are\n  generated for you automatically when using generators for controllers.\n  Helpers can be used to wrap functionality for your views into methods.\n\nconfig\n  Configuration files for the Rails environment, the routing map, the database,\n  and other dependencies.\n\ndb\n  Contains the database schema in schema.rb. db/migrate contains all the\n  sequence of Migrations for your schema.\n\ndoc\n  This directory is where your application documentation will be stored when\n  generated using <tt>rake doc:app</tt>\n\nlib\n  Application specific libraries. Basically, any kind of custom code that\n  doesn't belong under controllers, models, or helpers. This directory is in\n  the load path.\n\npublic\n  The directory available for the web server. Also contains the dispatchers and the\n  default HTML files. This should be set as the DOCUMENT_ROOT of your web\n  server.\n\nscript\n  Helper scripts for automation and generation.\n\ntest\n  Unit and functional tests along with fixtures. When using the rails generate\n  command, template test files will be generated for you and placed in this\n  directory.\n\nvendor\n  External libraries that the application depends on. Also includes the plugins\n  subdirectory. If the app has frozen rails, those gems also go here, under\n  vendor/rails/. This directory is in the load path.\n"
  },
  {
    "path": "components/event_counter/spec/dummy/Rakefile",
    "content": "#!/usr/bin/env rake\n# Add your own tasks in files placed in lib/tasks ending in .rake,\n# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.\n\nrequire File.expand_path('../config/application', __FILE__)\n\nDummy::Application.load_tasks\n"
  },
  {
    "path": "components/event_counter/spec/dummy/app/assets/javascripts/application.js",
    "content": "// This is a manifest file that'll be compiled into application.js, which will include all the files\n// listed below.\n//\n// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,\n// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.\n//\n// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the\n// the compiled file.\n//\n// WARNING: THE FIRST BLANK LINE MARKS THE END OF WHAT'S TO BE PROCESSED, ANY BLANK LINE SHOULD\n// GO AFTER THE REQUIRES BELOW.\n//\n//= require jquery\n//= require jquery_ujs\n//= require_tree .\n"
  },
  {
    "path": "components/event_counter/spec/dummy/app/assets/stylesheets/application.css",
    "content": "/*\n * This is a manifest file that'll be compiled into application.css, which will include all the files\n * listed below.\n *\n * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,\n * or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path.\n *\n * You're free to add application-wide styles to this file and they'll appear at the top of the\n * compiled file, but it's generally better to create a new file per style scope.\n *\n *= require_self\n *= require_tree .\n */\n"
  },
  {
    "path": "components/event_counter/spec/dummy/app/controllers/application_controller.rb",
    "content": "class ApplicationController < ActionController::Base\n  protect_from_forgery\nend\n"
  },
  {
    "path": "components/event_counter/spec/dummy/app/helpers/application_helper.rb",
    "content": "module ApplicationHelper\nend\n"
  },
  {
    "path": "components/event_counter/spec/dummy/app/mailers/.gitkeep",
    "content": ""
  },
  {
    "path": "components/event_counter/spec/dummy/app/models/.gitkeep",
    "content": ""
  },
  {
    "path": "components/event_counter/spec/dummy/app/views/layouts/application.html.erb",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>Dummy</title>\n  <%= stylesheet_link_tag    \"application\", :media => \"all\" %>\n  <%= javascript_include_tag \"application\" %>\n  <%= csrf_meta_tags %>\n</head>\n<body>\n\n<%= yield %>\n\n</body>\n</html>\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/application.rb",
    "content": "require File.expand_path('../boot', __FILE__)\n\n# Pick the frameworks you want:\nrequire \"active_record/railtie\"\nrequire \"action_controller/railtie\"\nrequire \"action_mailer/railtie\"\n# require \"active_resource/railtie\"\nrequire \"sprockets/railtie\"\n# require \"rails/test_unit/railtie\"\n\nBundler.require(*Rails.groups)\nrequire \"event_counter\"\n\nmodule Dummy\n  class Application < Rails::Application\n    # Settings in config/environments/* take precedence over those specified here.\n    # Application configuration should go into files in config/initializers\n    # -- all .rb files in that directory are automatically loaded.\n\n    # Custom directories with classes and modules you want to be autoloadable.\n    # config.autoload_paths += %W(#{config.root}/extras)\n\n    # Only load the plugins named here, in the order given (default is alphabetical).\n    # :all can be used as a placeholder for all plugins not explicitly named.\n    # config.plugins = [ :exception_notification, :ssl_requirement, :all ]\n\n    # Activate observers that should always be running.\n    # config.active_record.observers = :cacher, :garbage_collector, :forum_observer\n\n    # Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.\n    # Run \"rake -D time\" for a list of tasks for finding time zone names. Default is UTC.\n    # config.time_zone = 'Central Time (US & Canada)'\n\n    # The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.\n    # config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]\n    # config.i18n.default_locale = :de\n\n    # Configure the default encoding used in templates for Ruby 1.9.\n    config.encoding = \"utf-8\"\n\n    # Configure sensitive parameters which will be filtered from the log file.\n    config.filter_parameters += [:password]\n\n    # Enable escaping HTML in JSON.\n    config.active_support.escape_html_entities_in_json = true\n\n    # Use SQL instead of Active Record's schema dumper when creating the database.\n    # This is necessary if your schema can't be completely dumped by the schema dumper,\n    # like if you have constraints or database-specific column types\n    # config.active_record.schema_format = :sql\n\n    # Enable the asset pipeline\n    config.assets.enabled = true\n\n    # Version of your assets, change this if you want to expire all your assets\n    config.assets.version = '1.0'\n  end\nend\n\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/boot.rb",
    "content": "require 'rubygems'\ngemfile = File.expand_path('../../../../Gemfile', __FILE__)\n\nif File.exist?(gemfile)\n  ENV['BUNDLE_GEMFILE'] = gemfile\n  require 'bundler'\n  Bundler.setup\nend\n\n$:.unshift File.expand_path('../../../../lib', __FILE__)"
  },
  {
    "path": "components/event_counter/spec/dummy/config/database.yml",
    "content": "development:\n  adapter: sqlite3\n  database: db/development.sqlite3\n  pool: 5\n  timeout: 5000\n\ntest:\n  adapter: sqlite3\n  database: db/test.sqlite3\n  pool: 5\n  timeout: 5000\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/environment.rb",
    "content": "# Load the rails application\nrequire File.expand_path('../application', __FILE__)\n\n# Initialize the rails application\nDummy::Application.initialize!\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/environments/development.rb",
    "content": "Dummy::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # In the development environment your application's code is reloaded on\n  # every request. This slows down response time but is perfect for development\n  # since you don't have to restart the web server when you make code changes.\n  config.cache_classes = false\n\n  # Show full error reports and disable caching\n  config.consider_all_requests_local       = true\n  config.action_controller.perform_caching = false\n\n  # Don't care if the mailer can't send\n  config.action_mailer.raise_delivery_errors = false\n\n  # Print deprecation notices to the Rails logger\n  config.active_support.deprecation = :log\n\n  # Only use best-standards-support built into browsers\n  config.action_dispatch.best_standards_support = :builtin\n\n  # Log the query plan for queries taking more than this (works\n  # with SQLite, MySQL, and PostgreSQL)\n  # config.active_record.auto_explain_threshold_in_seconds = 0.5\n\n  # Do not compress assets\n  config.assets.compress = false\n\n  # Expands the lines which load the assets\n  config.assets.debug = true\n\n  config.eager_load = false\nend\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/environments/production.rb",
    "content": "Dummy::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # Code is not reloaded between requests\n  config.cache_classes = true\n\n  # Full error reports are disabled and caching is turned on\n  config.consider_all_requests_local       = false\n  config.action_controller.perform_caching = true\n\n  # Disable Rails's static asset server (Apache or nginx will already do this)\n  config.serve_static_assets = false\n\n  # Compress JavaScripts and CSS\n  config.assets.compress = true\n\n  # Don't fallback to assets pipeline if a precompiled asset is missed\n  config.assets.compile = false\n\n  # Generate digests for assets URLs\n  config.assets.digest = true\n\n  # Defaults to nil and saved in location specified by config.assets.prefix\n  # config.assets.manifest = YOUR_PATH\n\n  # Specifies the header that your server uses for sending files\n  # config.action_dispatch.x_sendfile_header = \"X-Sendfile\" # for apache\n  # config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for nginx\n\n  # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.\n  # config.force_ssl = true\n\n  # See everything in the log (default is :info)\n  # config.log_level = :debug\n\n  # Prepend all log lines with the following tags\n  # config.log_tags = [ :subdomain, :uuid ]\n\n  # Use a different logger for distributed setups\n  # config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new)\n\n  # Use a different cache store in production\n  # config.cache_store = :mem_cache_store\n\n  # Enable serving of images, stylesheets, and JavaScripts from an asset server\n  # config.action_controller.asset_host = \"http://assets.example.com\"\n\n  # Precompile additional assets (application.js, application.css, and all non-JS/CSS are already added)\n  # config.assets.precompile += %w( search.js )\n\n  # Disable delivery errors, bad email addresses will be ignored\n  # config.action_mailer.raise_delivery_errors = false\n\n  # Enable threaded mode\n  # config.threadsafe!\n\n  # Enable locale fallbacks for I18n (makes lookups for any locale fall back to\n  # the I18n.default_locale when a translation can not be found)\n  config.i18n.fallbacks = true\n\n  # Send deprecation notices to registered listeners\n  config.active_support.deprecation = :notify\n\n  # Log the query plan for queries taking more than this (works\n  # with SQLite, MySQL, and PostgreSQL)\n  # config.active_record.auto_explain_threshold_in_seconds = 0.5\n\n  config.eager_load = true\nend\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/environments/test.rb",
    "content": "Dummy::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # The test environment is used exclusively to run your application's\n  # test suite. You never need to work with it otherwise. Remember that\n  # your test database is \"scratch space\" for the test suite and is wiped\n  # and recreated between test runs. Don't rely on the data there!\n  config.cache_classes = true\n\n  # Configure static asset server for tests with Cache-Control for performance\n  config.serve_static_assets = true\n  config.static_cache_control = \"public, max-age=3600\"\n\n  # Show full error reports and disable caching\n  config.consider_all_requests_local       = true\n  config.action_controller.perform_caching = false\n\n  # Raise exceptions instead of rendering exception templates\n  config.action_dispatch.show_exceptions = false\n\n  # Disable request forgery protection in test environment\n  config.action_controller.allow_forgery_protection    = false\n\n  # Tell Action Mailer not to deliver emails to the real world.\n  # The :test delivery method accumulates sent emails in the\n  # ActionMailer::Base.deliveries array.\n  config.action_mailer.delivery_method = :test\n\n  # Print deprecation notices to the stderr\n  config.active_support.deprecation = :stderr\n\n  config.eager_load = false\nend\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/initializers/backtrace_silencers.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces.\n# Rails.backtrace_cleaner.add_silencer { |line| line =~ /my_noisy_library/ }\n\n# You can also remove all the silencers if you're trying to debug a problem that might stem from framework code.\n# Rails.backtrace_cleaner.remove_silencers!\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/initializers/inflections.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Add new inflection rules using the following format\n# (all these examples are active by default):\n# ActiveSupport::Inflector.inflections do |inflect|\n#   inflect.plural /^(ox)$/i, '\\1en'\n#   inflect.singular /^(ox)en/i, '\\1'\n#   inflect.irregular 'person', 'people'\n#   inflect.uncountable %w( fish sheep )\n# end\n#\n# These inflection rules are supported but not enabled by default:\n# ActiveSupport::Inflector.inflections do |inflect|\n#   inflect.acronym 'RESTful'\n# end\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/initializers/mime_types.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Add new mime types for use in respond_to blocks:\n# Mime::Type.register \"text/richtext\", :rtf\n# Mime::Type.register_alias \"text/html\", :iphone\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/initializers/secret_token.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Your secret key for verifying the integrity of signed cookies.\n# If you change this key, all old signed cookies will become invalid!\n# Make sure the secret is at least 30 characters and all random,\n# no regular words or you'll be exposed to dictionary attacks.\nDummy::Application.config.secret_token = '99d74f03672b06736bb127b8d46ea37b12376b45784c496263c0cfe4961387f398798a00e033b5f0de0ebe63dba51aaaa952f070fb72a7420c472a7ed88feea7'\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/initializers/session_store.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\nDummy::Application.config.session_store :cookie_store, key: '_dummy_session'\n\n# Use the database for sessions instead of the cookie-based default,\n# which shouldn't be used to store highly confidential information\n# (create the session table with \"rails generate session_migration\")\n# Dummy::Application.config.session_store :active_record_store\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/initializers/wrap_parameters.rb",
    "content": "# Be sure to restart your server when you modify this file.\n#\n# This file contains settings for ActionController::ParamsWrapper which\n# is enabled by default.\n\n# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.\nActiveSupport.on_load(:action_controller) do\n  wrap_parameters format: [:json]\nend\n\n# Disable root element in JSON by default.\nActiveSupport.on_load(:active_record) do\n  self.include_root_in_json = false\nend\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/locales/en.yml",
    "content": "# Sample localization file for English. Add more files in this directory for other locales.\n# See https://github.com/svenfuchs/rails-i18n/tree/master/rails%2Flocale for starting points.\n\nen:\n  hello: \"Hello world\"\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config/routes.rb",
    "content": "Rails.application.routes.draw do\n\n  mount EventCounter::Engine => \"/event_counter\"\nend\n"
  },
  {
    "path": "components/event_counter/spec/dummy/config.ru",
    "content": "# This file is used by Rack-based servers to start the application.\n\nrequire ::File.expand_path('../config/environment',  __FILE__)\nrun Dummy::Application\n"
  },
  {
    "path": "components/event_counter/spec/dummy/db/schema.rb",
    "content": "# encoding: UTF-8\n# This file is auto-generated from the current state of the database. Instead\n# of editing this file, please use the migrations feature of Active Record to\n# incrementally modify your database, and then regenerate this schema definition.\n#\n# Note that this schema.rb definition is the authoritative source for your\n# database schema. If you need to create the application database on another\n# system, you should be using db:schema:load, not running all the migrations\n# from scratch. The latter is a flawed and unsustainable approach (the more migrations\n# you'll amass, the slower it'll run and the greater likelihood for issues).\n#\n# It's strongly recommended that you check this file into your version control system.\n\nActiveRecord::Schema.define(version: 20130403021547) do\n\n  create_table \"event_counter_counts\", force: true do |t|\n    t.string  \"object_identifier\"\n    t.string  \"event_identifier\"\n    t.integer \"count\",             default: 0\n  end\n\nend\n"
  },
  {
    "path": "components/event_counter/spec/dummy/lib/assets/.gitkeep",
    "content": ""
  },
  {
    "path": "components/event_counter/spec/dummy/log/.gitkeep",
    "content": ""
  },
  {
    "path": "components/event_counter/spec/dummy/public/404.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>The page you were looking for doesn't exist (404)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/404.html -->\n  <div class=\"dialog\">\n    <h1>The page you were looking for doesn't exist.</h1>\n    <p>You may have mistyped the address or the page may have moved.</p>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "components/event_counter/spec/dummy/public/422.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>The change you wanted was rejected (422)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/422.html -->\n  <div class=\"dialog\">\n    <h1>The change you wanted was rejected.</h1>\n    <p>Maybe you tried to change something you didn't have access to.</p>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "components/event_counter/spec/dummy/public/500.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>We're sorry, but something went wrong (500)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/500.html -->\n  <div class=\"dialog\">\n    <h1>We're sorry, but something went wrong.</h1>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "components/event_counter/spec/dummy/script/rails",
    "content": "#!/usr/bin/env ruby\n# This command will automatically be run when you run \"rails\" with Rails 3 gems installed from the root of your application.\n\nAPP_PATH = File.expand_path('../../config/application',  __FILE__)\nrequire File.expand_path('../../config/boot',  __FILE__)\nrequire 'rails/commands'\n"
  },
  {
    "path": "components/event_counter/spec/models/logger_spec.rb",
    "content": "require \"spec_helper\"\n\nmodule EventCounter\n  describe EventCounter::Logger do\n    describe \"#log\" do\n      it \"returns the new logged count\" do\n        subject.log(\"some_object\", \"some_event\").should == 1\n        subject.log(\"some_object\", \"some_event\").should == 2\n        subject.log(\"some_object\", \"some_event\").should == 3\n\n        subject.log(\"some_object\", \"some_other_event\").should == 1\n        subject.log(\"some_other_object\", \"some_event\").should == 1\n      end\n    end\n  end\nend\n"
  },
  {
    "path": "components/event_counter/spec/spec_helper.rb",
    "content": "# This file is copied to spec/ when you run 'rails generate rspec:install'\nENV[\"RAILS_ENV\"] ||= 'test'\nrequire File.expand_path(\"../dummy/config/environment\", __FILE__)\nrequire 'rspec/rails'\nrequire 'rspec/autorun'\nrequire 'shoulda-matchers'\n\nDir[EventCounter::Engine.root.join(\"spec/support/**/*.rb\")].each {|f| require f}\n\nRSpec.configure do |config|\n  config.use_transactional_fixtures = true\n  config.infer_base_class_for_anonymous_controllers = false\n  config.order = \"random\"\nend\n"
  },
  {
    "path": "components/event_counter/spec/support/test_helper.rb",
    "content": "module EventCounter\n  module TestHelper\n    def self.new_logger(object_identifier = nil, event_identifier = nil, count = nil)\n      logger = EventCounter::Logger.new\n      if object_identifier && event_identifier && count\n        count.times do\n          logger.log object_identifier, event_identifier\n        end\n      end\n      logger\n    end\n  end\nend"
  },
  {
    "path": "components/event_counter/test.sh",
    "content": "#!/bin/bash\n\nexit_code=0\n\necho \"*** Running event counter specs\"\nbundle install --jobs=3 --retry=3 | grep Installing\nbundle exec rake db:create db:migrate #don't remove this line. If only run in test our schema.rb doesn't include required engine's migrations\nRAILS_ENV=test bundle exec rake db:create db:migrate\nbundle exec rspec spec/models\nexit_code+=$?\n\nexit $exit_code"
  },
  {
    "path": "components/teaser/.gitignore",
    "content": ".bundle/\nlog/*.log\npkg/\nspec/dummy/db/*.sqlite3\nspec/dummy/log/*.log\nspec/dummy/tmp/\nspec/dummy/.sass-cache\n"
  },
  {
    "path": "components/teaser/.rspec",
    "content": "--color\n"
  },
  {
    "path": "components/teaser/.ruby-gemset",
    "content": "tnbtt\n"
  },
  {
    "path": "components/teaser/.ruby-version",
    "content": "2.1.0\n"
  },
  {
    "path": "components/teaser/Gemfile",
    "content": "source \"https://rubygems.org\"\ngemspec\n\ngem 'jasmine-core', github: 'pivotal/jasmine'\ngem 'jasmine', github: 'pivotal/jasmine-gem'\n\n\npath '../' do\n  gem \"annoyance\"\n  gem \"email_signup\"\n  gem \"event_counter\"\nend"
  },
  {
    "path": "components/teaser/MIT-LICENSE",
    "content": "Copyright 2012 YOURNAME\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": "components/teaser/README.rdoc",
    "content": "= Teaser\n\nThis project rocks and uses MIT-LICENSE."
  },
  {
    "path": "components/teaser/Rakefile",
    "content": "#!/usr/bin/env rake\nbegin\n  require 'bundler/setup'\nrescue LoadError\n  puts 'You must `gem install bundler` and `bundle install` to run rake tasks'\nend\nbegin\n  require 'rdoc/task'\nrescue LoadError\n  require 'rdoc/rdoc'\n  require 'rake/rdoctask'\n  RDoc::Task = Rake::RDocTask\nend\n\nRDoc::Task.new(:rdoc) do |rdoc|\n  rdoc.rdoc_dir = 'rdoc'\n  rdoc.title    = 'Teaser'\n  rdoc.options << '--line-numbers'\n  rdoc.rdoc_files.include('README.rdoc')\n  rdoc.rdoc_files.include('lib/**/*.rb')\nend\n\nAPP_RAKEFILE = File.expand_path(\"../spec/dummy/Rakefile\", __FILE__)\nload 'rails/tasks/engine.rake'\n\n\n\nBundler::GemHelper.install_tasks\n\nrequire \"rspec/core/rake_task\"\n\nRSpec::Core::RakeTask.new(:rspec) do |spec|\n  spec.pattern = 'spec/**/*_spec.rb'\nend\n\ntask :default => :rspec\n"
  },
  {
    "path": "components/teaser/app/assets/images/teaser/.gitkeep",
    "content": ""
  },
  {
    "path": "components/teaser/app/assets/javascripts/teaser/application.js",
    "content": "// This is a manifest file that'll be compiled into application.js, which will include all the files\n// listed below.\n//\n// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,\n// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.\n//\n// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the\n// the compiled file.\n//\n// WARNING: THE FIRST BLANK LINE MARKS THE END OF WHAT'S TO BE PROCESSED, ANY BLANK LINE SHOULD\n// GO AFTER THE REQUIRES BELOW.\n//\n//= require jquery\n//= require jquery_ujs\n//= require ./teaser\n//= require_tree .\n//= require_self\n\n(new Teaser.SignUp).initialize('#signup', '#results', window.createTeaserUrl);"
  },
  {
    "path": "components/teaser/app/assets/javascripts/teaser/signUp.js",
    "content": "Teaser.SignUp = function () {\n}\n\nTeaser.SignUp.prototype.initialize = function (inputSelector, resultSelector, signUpEndpoint) {\n    this.signUpEndpoint = signUpEndpoint;\n    this.$inputElement = $(inputSelector);\n    this.$resultElement = $(resultSelector);\n    this.$inputElement.on(\"keydown\", $.proxy(this.signUpIfSubmitted, this));\n}\n\nTeaser.SignUp.prototype.signUp = function () {\n    var that = this;\n    $.post(this.signUpEndpoint, { new_sign_up_entry:this.$inputElement.val() }, function (data) {\n    })\n        .success(function (result) {\n            $.proxy(that.handleSubmissionResult(\"success\", result), that)\n        })\n        .error(function (result) {\n            $.proxy(that.handleSubmissionResult(\"error\", result), that)\n        });\n}\n\nTeaser.SignUp.prototype.signUpIfSubmitted = function (e) {\n    var key = (e.keyCode ? e.keyCode : e.which);\n    if (key == 13) {\n        e.preventDefault();\n        $.proxy(this.signUp(), this);\n    }\n}\n\nTeaser.SignUp.prototype.handleSubmissionResult = function (result, data) {\n    var responseText = data.responseText || data;\n    this.$resultElement.prepend(\"<p class='\" + result + \"'>\" + responseText + \"</p>\");\n}"
  },
  {
    "path": "components/teaser/app/assets/javascripts/teaser/teaser.js",
    "content": "Teaser = {}\n"
  },
  {
    "path": "components/teaser/app/assets/stylesheets/teaser/application.css",
    "content": "/*\n * This is a manifest file that'll be compiled into application.css, which will include all the files\n * listed below.\n *\n * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,\n * or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path.\n *\n * You're free to add application-wide styles to this file and they'll appear at the top of the\n * compiled file, but it's generally better to create a new file per style scope.\n *\n *= require_self\n *= require_tree .\n */\n"
  },
  {
    "path": "components/teaser/app/assets/stylesheets/teaser/teaser.css.scss",
    "content": "/*\n * Colors from http://design-seeds.com/index.php/home/entry/a-door-green1\n *\n * Thanks to design seeds!\n */\n\n$lightgreen: #e4e8ae;\n$browngreen: #786f27;\n$gray: #b5acad;\n$darkgray: #424343;\n$midgreen: #cfcb65;\n$darkgreen: #758559;\n\n/*\n * You are allowed to do whatever you want with this layout. Though I would be pleased if you placed a link on your site to csseasy.com or to profit42.com (best \"blog about hacking\" ever). Donations are also welcome: paypal@profit42.com (or follow the donation button on csseasy.com)\n *\n * Thanks to css easy!\n */\n\n* {\n  font-family: 'Lucida Sans Unicode';\n}\n\nbody {\n  background-color: $midgreen;\n  font-size: 16px;\n  margin: 0;\n  padding: 0;\n}\n\n#header {\n  background-color: $browngreen;\n  height: 90px;\n  padding: 50px;\n  font-size: 80px;\n  text-align: center;\n  color: #fff;\n  text-shadow: black 0.05em 0.05em 0.05em;\n}\n\n#top {\n  width: 100%;\n  background-color: $midgreen;\n  height: 50px;\n}\n\n#center {\n  background-color: $lightgreen;\n  min-height: 600px; /* for modern browsers */\n  height: auto !important; /* for modern browsers */\n  height: 600px; /* for IE5.x and IE6 */\n  text-align: center;\n  color: #fff;\n}\n\n#footer {\n  clear: both;\n  background-color: $browngreen;\n  height: 200px;\n}\n\n#content {\n  font-size: 28px;\n  padding: 80px 0px;\n  text-align: center;\n  color: $darkgray;\n  p {\n    line-height: 28px;\n  }\n  input {\n    background-color: white;\n    border: 1px solid $gray;\n    -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);\n    -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);\n    box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);\n    -webkit-transition: border linear 0.2s, box-shadow linear 0.2s;\n    -moz-transition: border linear 0.2s, box-shadow linear 0.2s;\n    -o-transition: border linear 0.2s, box-shadow linear 0.2s;\n    transition: border linear 0.2s, box-shadow linear 0.2s;\n    display: inline-block;\n    height: 20px;\n    width: 200px;\n    padding: 4px 6px;\n    margin-top: 20px;\n    margin-bottom: 9px;\n    font-size: 14px;\n    line-height: 20px;\n    -webkit-border-radius: 3px;\n    -moz-border-radius: 3px;\n    border-radius: 3px;\n  }\n}"
  },
  {
    "path": "components/teaser/app/controllers/teaser/application_controller.rb",
    "content": "module Teaser\n  class ApplicationController < ActionController::Base\n  end\nend\n"
  },
  {
    "path": "components/teaser/app/controllers/teaser/tease_controller.rb",
    "content": "module Teaser\n  class TeaseController < Teaser::ApplicationController\n\n    before_filter :inject_dependencies, only: [:create]\n\n    def new\n    end\n\n    def create\n      email = params[:new_sign_up_entry].presence\n      render text: \"Hey! Please call this right... I need a new signUp entry!\", status: 400 and return unless email\n\n      if similar_exisiting_entry = @entry_manager.find_by_email(email)\n        tries = @event_counter.log(\"email_signup_entry_#{similar_exisiting_entry.id}\", \"signup\")\n        render(\n            text: @annoyance_meter.annoyance_adjusted(\"Hm... Did you already sign up?\", tries),\n            status: 400) and return\n      elsif @entry_manager.create(email)\n        render text: \"Thanks for signing up!\", status: 200\n      else\n        render text: \"Hm... something went seriously wrong.\", status: 500\n      end\n    end\n\n    private\n\n    def inject_dependencies\n      @entry_manager = EmailSignup::EntryManager.new\n      @annoyance_meter = Annoyance::Meter.new(10)\n      @event_counter = EventCounter::Logger.new\n    end\n  end\nend"
  },
  {
    "path": "components/teaser/app/views/layouts/teaser/application.html.erb",
    "content": "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.1//EN\" \"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd\">\n<html xmlns=\"http://www.w3.org/1999/xhtml\" xml:lang=\"en\">\n<head>\n  <title>Teaser</title>\n  <%= stylesheet_link_tag \"teaser/application\", :media => \"all\" %>\n  <%= csrf_meta_tags %>\n</head>\n<body>\n<div id=\"header\">\n  <%= content_for :header %>\n</div>\n<div id=\"top\">\n  <%= content_for :top %>\n</div>\n<a href=\"https://github.com/shageman/the_next_big_thing\">\n  <img style=\"position: absolute; top: 0; right: 0; border: 0;\" src=\"https://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png\" alt=\"Fork me on GitHub\">\n</a>\n<div id=\"center\">\n  <div id=\"content\">\n    <%= yield %>\n  </div>\n</div>\n<div id=\"footer\">\n  <%= content_for :footer %>\n</div>\n</body>\n<%= javascript_include_tag \"teaser/application\" %>\n</html>"
  },
  {
    "path": "components/teaser/app/views/teaser/tease/new.html.haml",
    "content": "-content_for :header do\n  The Next Big Thing\n\n%p Find nothing out about it right here!\n\n%p Also: sign up to receive our updates\n\n%form\n  %input#signup\n\n#results\n\n:javascript\n  window.createTeaserUrl = \"#{tease_index_url}\";"
  },
  {
    "path": "components/teaser/config/routes.rb",
    "content": "Teaser::Engine.routes.draw do\n  resources \"tease\", only: [:new, :create]\n  root :to => 'tease#new'\nend\n"
  },
  {
    "path": "components/teaser/db/migrate/20120915205848_create_entry.rb",
    "content": "class CreateEntry < ActiveRecord::Migration\n  def change\n    create_table :teaser_entries do |t|\n      t.string :email\n\n      t.timestamps\n    end\n  end\nend\n"
  },
  {
    "path": "components/teaser/db/migrate/20120917081547_add_tries_to_teaser_entries.rb",
    "content": "class AddTriesToTeaserEntries < ActiveRecord::Migration\n  def change\n    add_column :teaser_entries, :tries, :integer, default: 0\n  end\nend\n"
  },
  {
    "path": "components/teaser/db/migrate/20130403011500_remove_entry.rb",
    "content": "class RemoveEntry < ActiveRecord::Migration\n  def change\n    drop_table :teaser_entries\n  end\nend\n"
  },
  {
    "path": "components/teaser/lib/monkey_patches/engine.rb",
    "content": "module Rails\n  class Engine < Railtie\n    def load_seed\n      seed_files = paths[\"db/seeds\"]\n      seed_files.each do |seed_file|\n        load(seed_file)\n      end\n    end\n  end\nend\n"
  },
  {
    "path": "components/teaser/lib/tasks/teaser_tasks.rake",
    "content": "# desc \"Explaining what the task does\"\n# task :teaser do\n#   # Task goes here\n# end\n"
  },
  {
    "path": "components/teaser/lib/teaser/engine.rb",
    "content": "module Teaser\n  class Engine < ::Rails::Engine\n    isolate_namespace Teaser\n\n    initializer :append_migrations do |app|\n      unless app.root.to_s.match root.to_s + File::SEPARATOR\n        config.paths[\"db/migrate\"].expanded.each do |path|\n          app.config.paths[\"db/migrate\"] << path\n        end\n      end\n    end\n  end\nend\n"
  },
  {
    "path": "components/teaser/lib/teaser/version.rb",
    "content": "module Teaser\n  VERSION = \"0.0.1\"\nend\n"
  },
  {
    "path": "components/teaser/lib/teaser.rb",
    "content": "require \"teaser/engine\"\nrequire \"rails/all\"\nrequire \"haml\"\nrequire \"jquery-rails\"\nrequire \"annoyance\"\nrequire \"event_counter\"\n\nrequire File.expand_path(\"../monkey_patches/engine.rb\", __FILE__)\n\nmodule Teaser\nend\n"
  },
  {
    "path": "components/teaser/script/rails",
    "content": "#!/usr/bin/env ruby\n# This command will automatically be run when you run \"rails\" with Rails 3 gems installed from the root of your application.\n\nENGINE_ROOT = File.expand_path('../..', __FILE__)\nENGINE_PATH = File.expand_path('../../lib/teaser/engine', __FILE__)\n\nrequire 'rails/all'\nrequire 'rails/engine/commands'\n"
  },
  {
    "path": "components/teaser/spec/controllers/tease_controller_spec.rb",
    "content": "require \"spec_helper\"\n\nmodule Teaser\n  describe TeaseController, type: :controller do\n    before do\n      controller.stub(:inject_dependencies)\n    end\n\n    describe \"GET new\" do\n      it \"should not fail\" do\n        expect {\n          get :new, use_route: \"teaser\"\n        }.to_not raise_exception\n      end\n    end\n\n    describe \"POST create\" do\n      it \"should use the annoyance meter set to 20\" do\n        controller.unstub(:inject_dependencies)\n        Annoyance::Meter.should_receive(:new).with(10)\n        xhr :post, :create, use_route: \"teaser\"\n      end\n\n      it \"should fail if no new_sign_up_entry parameter is given\" do\n        xhr :post, :create, use_route: \"teaser\"\n        response.status.should == 400\n        response.body.should == \"Hey! Please call this right... I need a new signUp entry!\"\n\n        xhr :post, :create, new_sign_up_entry: nil, use_route: \"teaser\"\n        response.status.should == 400\n        response.body.should == \"Hey! Please call this right... I need a new signUp entry!\"\n      end\n\n      it \"should fail if the given new_sign_up_entry already exists (and use the annoyance meter)\" do\n        mock_annoyance_meter = double(\"annoyance_meter\", annoyance_adjusted: \"Oh I am annoyed...\")\n        controller.instance_variable_set \"@annoyance_meter\", mock_annoyance_meter\n        entry_manager = EmailSignup::EntryManager.new\n        controller.instance_variable_set \"@entry_manager\", entry_manager\n        entry = entry_manager.create \"adam\"\n\n        event_counter = EventCounter::TestHelper.new_logger(\"email_signup_entry_#{entry.id}\", \"signup\", 1)\n        controller.instance_variable_set \"@event_counter\", event_counter\n\n        xhr :post, :create, new_sign_up_entry: \"adam\", use_route: \"teaser\"\n        response.status.should == 400\n        response.body.should == \"Oh I am annoyed...\"\n        EventCounter::Logger::Count.first.count.should == 2\n      end\n\n      it \"should fail if the new entry cannot be saved\" do\n        entry_manager = double(\"entry_manager\", create: false, find_by_email: nil)\n        controller.instance_variable_set \"@entry_manager\", entry_manager\n\n        xhr :post, :create, new_sign_up_entry: \"something unsaveable\", use_route: \"teaser\"\n        response.status.should == 500\n        response.body.should == \"Hm... something went seriously wrong.\"\n      end\n\n      it \"should be a success if the new entry can be saved\" do\n        entry_manager = double(\"entry_manager\", create: true, find_by_email: nil)\n        controller.instance_variable_set \"@entry_manager\", entry_manager\n\n        xhr :post, :create, new_sign_up_entry: \"something unsaveable\", use_route: \"teaser\"\n        response.status.should == 200\n        response.body.should == \"Thanks for signing up!\"\n      end\n    end\n  end\nend"
  },
  {
    "path": "components/teaser/spec/dummy/README.rdoc",
    "content": "== Welcome to Rails\n\nRails is a web-application framework that includes everything needed to create\ndatabase-backed web applications according to the Model-View-Control pattern.\n\nThis pattern splits the view (also called the presentation) into \"dumb\"\ntemplates that are primarily responsible for inserting pre-built data in between\nHTML tags. The model contains the \"smart\" domain objects (such as Account,\nProduct, Person, Post) that holds all the business logic and knows how to\npersist themselves to a database. The controller handles the incoming requests\n(such as Save New Account, Update Product, Show Post) by manipulating the model\nand directing data to the view.\n\nIn Rails, the model is handled by what's called an object-relational mapping\nlayer entitled Active Record. This layer allows you to present the data from\ndatabase rows as objects and embellish these data objects with business logic\nmethods. You can read more about Active Record in\nlink:files/vendor/rails/activerecord/README.html.\n\nThe controller and view are handled by the Action Pack, which handles both\nlayers by its two parts: Action View and Action Controller. These two layers\nare bundled in a single package due to their heavy interdependence. This is\nunlike the relationship between the Active Record and Action Pack that is much\nmore separate. Each of these packages can be used independently outside of\nRails. You can read more about Action Pack in\nlink:files/vendor/rails/actionpack/README.html.\n\n\n== Getting Started\n\n1. At the command prompt, create a new Rails application:\n       <tt>rails new myapp</tt> (where <tt>myapp</tt> is the application name)\n\n2. Change directory to <tt>myapp</tt> and start the web server:\n       <tt>cd myapp; rails server</tt> (run with --help for options)\n\n3. Go to http://localhost:3000/ and you'll see:\n       \"Welcome aboard: You're riding Ruby on Rails!\"\n\n4. Follow the guidelines to start developing your application. You can find\nthe following resources handy:\n\n* The Getting Started Guide: http://guides.rubyonrails.org/getting_started.html\n* Ruby on Rails Tutorial Book: http://www.railstutorial.org/\n\n\n== Debugging Rails\n\nSometimes your application goes wrong. Fortunately there are a lot of tools that\nwill help you debug it and get it back on the rails.\n\nFirst area to check is the application log files. Have \"tail -f\" commands\nrunning on the server.log and development.log. Rails will automatically display\ndebugging and runtime information to these files. Debugging info will also be\nshown in the browser on requests from 127.0.0.1.\n\nYou can also log your own messages directly into the log file from your code\nusing the Ruby logger class from inside your controllers. Example:\n\n  class WeblogController < ActionController::Base\n    def destroy\n      @weblog = Weblog.find(params[:id])\n      @weblog.destroy\n      logger.info(\"#{Time.now} Destroyed Weblog ID ##{@weblog.id}!\")\n    end\n  end\n\nThe result will be a message in your log file along the lines of:\n\n  Mon Oct 08 14:22:29 +1000 2007 Destroyed Weblog ID #1!\n\nMore information on how to use the logger is at http://www.ruby-doc.org/core/\n\nAlso, Ruby documentation can be found at http://www.ruby-lang.org/. There are\nseveral books available online as well:\n\n* Programming Ruby: http://www.ruby-doc.org/docs/ProgrammingRuby/ (Pickaxe)\n* Learn to Program: http://pine.fm/LearnToProgram/ (a beginners guide)\n\nThese two books will bring you up to speed on the Ruby language and also on\nprogramming in general.\n\n\n== Debugger\n\nDebugger support is available through the debugger command when you start your\nMongrel or WEBrick server with --debugger. This means that you can break out of\nexecution at any point in the code, investigate and change the model, and then,\nresume execution! You need to install ruby-debug to run the server in debugging\nmode. With gems, use <tt>sudo gem install ruby-debug</tt>. Example:\n\n  class WeblogController < ActionController::Base\n    def index\n      @posts = Post.all\n      debugger\n    end\n  end\n\nSo the controller will accept the action, run the first line, then present you\nwith a IRB prompt in the server window. Here you can do things like:\n\n  >> @posts.inspect\n  => \"[#<Post:0x14a6be8\n          @attributes={\"title\"=>nil, \"body\"=>nil, \"id\"=>\"1\"}>,\n       #<Post:0x14a6620\n          @attributes={\"title\"=>\"Rails\", \"body\"=>\"Only ten..\", \"id\"=>\"2\"}>]\"\n  >> @posts.first.title = \"hello from a debugger\"\n  => \"hello from a debugger\"\n\n...and even better, you can examine how your runtime objects actually work:\n\n  >> f = @posts.first\n  => #<Post:0x13630c4 @attributes={\"title\"=>nil, \"body\"=>nil, \"id\"=>\"1\"}>\n  >> f.\n  Display all 152 possibilities? (y or n)\n\nFinally, when you're ready to resume execution, you can enter \"cont\".\n\n\n== Console\n\nThe console is a Ruby shell, which allows you to interact with your\napplication's domain model. Here you'll have all parts of the application\nconfigured, just like it is when the application is running. You can inspect\ndomain models, change values, and save to the database. Starting the script\nwithout arguments will launch it in the development environment.\n\nTo start the console, run <tt>rails console</tt> from the application\ndirectory.\n\nOptions:\n\n* Passing the <tt>-s, --sandbox</tt> argument will rollback any modifications\n  made to the database.\n* Passing an environment name as an argument will load the corresponding\n  environment. Example: <tt>rails console production</tt>.\n\nTo reload your controllers and models after launching the console run\n<tt>reload!</tt>\n\nMore information about irb can be found at:\nlink:http://www.rubycentral.org/pickaxe/irb.html\n\n\n== dbconsole\n\nYou can go to the command line of your database directly through <tt>rails\ndbconsole</tt>. You would be connected to the database with the credentials\ndefined in database.yml. Starting the script without arguments will connect you\nto the development database. Passing an argument will connect you to a different\ndatabase, like <tt>rails dbconsole production</tt>. Currently works for MySQL,\nPostgreSQL and SQLite 3.\n\n== Description of Contents\n\nThe default directory structure of a generated Ruby on Rails application:\n\n  |-- app\n  |   |-- assets\n  |       |-- images\n  |       |-- javascripts\n  |       `-- stylesheets\n  |   |-- controllers\n  |   |-- helpers\n  |   |-- mailers\n  |   |-- models\n  |   `-- views\n  |       `-- layouts\n  |-- config\n  |   |-- environments\n  |   |-- initializers\n  |   `-- locales\n  |-- db\n  |-- doc\n  |-- lib\n  |   `-- tasks\n  |-- log\n  |-- public\n  |-- script\n  |-- test\n  |   |-- fixtures\n  |   |-- functional\n  |   |-- integration\n  |   |-- performance\n  |   `-- unit\n  |-- tmp\n  |   |-- cache\n  |   |-- pids\n  |   |-- sessions\n  |   `-- sockets\n  `-- vendor\n      |-- assets\n          `-- stylesheets\n      `-- plugins\n\napp\n  Holds all the code that's specific to this particular application.\n\napp/assets\n  Contains subdirectories for images, stylesheets, and JavaScript files.\n\napp/controllers\n  Holds controllers that should be named like weblogs_controller.rb for\n  automated URL mapping. All controllers should descend from\n  ApplicationController which itself descends from ActionController::Base.\n\napp/models\n  Holds models that should be named like post.rb. Models descend from\n  ActiveRecord::Base by default.\n\napp/views\n  Holds the template files for the view that should be named like\n  weblogs/index.html.erb for the WeblogsController#index action. All views use\n  eRuby syntax by default.\n\napp/views/layouts\n  Holds the template files for layouts to be used with views. This models the\n  common header/footer method of wrapping views. In your views, define a layout\n  using the <tt>layout :default</tt> and create a file named default.html.erb.\n  Inside default.html.erb, call <% yield %> to render the view using this\n  layout.\n\napp/helpers\n  Holds view helpers that should be named like weblogs_helper.rb. These are\n  generated for you automatically when using generators for controllers.\n  Helpers can be used to wrap functionality for your views into methods.\n\nconfig\n  Configuration files for the Rails environment, the routing map, the database,\n  and other dependencies.\n\ndb\n  Contains the database schema in schema.rb. db/migrate contains all the\n  sequence of Migrations for your schema.\n\ndoc\n  This directory is where your application documentation will be stored when\n  generated using <tt>rake doc:app</tt>\n\nlib\n  Application specific libraries. Basically, any kind of custom code that\n  doesn't belong under controllers, models, or helpers. This directory is in\n  the load path.\n\npublic\n  The directory available for the web server. Also contains the dispatchers and the\n  default HTML files. This should be set as the DOCUMENT_ROOT of your web\n  server.\n\nscript\n  Helper scripts for automation and generation.\n\ntest\n  Unit and functional tests along with fixtures. When using the rails generate\n  command, template test files will be generated for you and placed in this\n  directory.\n\nvendor\n  External libraries that the application depends on. Also includes the plugins\n  subdirectory. If the app has frozen rails, those gems also go here, under\n  vendor/rails/. This directory is in the load path.\n"
  },
  {
    "path": "components/teaser/spec/dummy/Rakefile",
    "content": "#!/usr/bin/env rake\n# Add your own tasks in files placed in lib/tasks ending in .rake,\n# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.\n\nrequire File.expand_path('../config/application', __FILE__)\n\nDummy::Application.load_tasks\n"
  },
  {
    "path": "components/teaser/spec/dummy/app/assets/javascripts/application.js",
    "content": "// This is a manifest file that'll be compiled into application.js, which will include all the files\n// listed below.\n//\n// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,\n// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.\n//\n// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the\n// the compiled file.\n//\n// WARNING: THE FIRST BLANK LINE MARKS THE END OF WHAT'S TO BE PROCESSED, ANY BLANK LINE SHOULD\n// GO AFTER THE REQUIRES BELOW.\n//\n//= require jquery\n//= require jquery_ujs\n//= require_tree .\n"
  },
  {
    "path": "components/teaser/spec/dummy/app/assets/stylesheets/application.css",
    "content": "/*\n * This is a manifest file that'll be compiled into application.css, which will include all the files\n * listed below.\n *\n * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,\n * or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path.\n *\n * You're free to add application-wide styles to this file and they'll appear at the top of the\n * compiled file, but it's generally better to create a new file per style scope.\n *\n *= require_self\n *= require_tree .\n */\n"
  },
  {
    "path": "components/teaser/spec/dummy/app/controllers/application_controller.rb",
    "content": "class ApplicationController < ActionController::Base\n  protect_from_forgery\nend\n"
  },
  {
    "path": "components/teaser/spec/dummy/app/helpers/application_helper.rb",
    "content": "module ApplicationHelper\nend\n"
  },
  {
    "path": "components/teaser/spec/dummy/app/mailers/.gitkeep",
    "content": ""
  },
  {
    "path": "components/teaser/spec/dummy/app/models/.gitkeep",
    "content": ""
  },
  {
    "path": "components/teaser/spec/dummy/app/views/layouts/application.html.erb",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>Dummy</title>\n  <%= stylesheet_link_tag    \"application\", :media => \"all\" %>\n  <%= javascript_include_tag \"application\" %>\n  <%= csrf_meta_tags %>\n</head>\n<body>\n\n<%= yield %>\n\n</body>\n</html>\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/application.rb",
    "content": "require File.expand_path('../boot', __FILE__)\n\nrequire \"rails/all\"\n\nBundler.require\nrequire \"teaser\"\n\nmodule Dummy\n  class Application < Rails::Application\n    # Settings in config/environments/* take precedence over those specified here.\n    # Application configuration should go into files in config/initializers\n    # -- all .rb files in that directory are automatically loaded.\n\n    # Custom directories with classes and modules you want to be autoloadable.\n    # config.autoload_paths += %W(#{config.root}/extras)\n\n    # Only load the plugins named here, in the order given (default is alphabetical).\n    # :all can be used as a placeholder for all plugins not explicitly named.\n    # config.plugins = [ :exception_notification, :ssl_requirement, :all ]\n\n    # Activate observers that should always be running.\n    # config.active_record.observers = :cacher, :garbage_collector, :forum_observer\n\n    # Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.\n    # Run \"rake -D time\" for a list of tasks for finding time zone names. Default is UTC.\n    # config.time_zone = 'Central Time (US & Canada)'\n\n    # The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.\n    # config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]\n    # config.i18n.default_locale = :de\n\n    # Configure the default encoding used in templates for Ruby 1.9.\n    config.encoding = \"utf-8\"\n\n    # Configure sensitive parameters which will be filtered from the log file.\n    config.filter_parameters += [:password]\n\n    # Enable escaping HTML in JSON.\n    config.active_support.escape_html_entities_in_json = true\n\n    # Use SQL instead of Active Record's schema dumper when creating the database.\n    # This is necessary if your schema can't be completely dumped by the schema dumper,\n    # like if you have constraints or database-specific column types\n    # config.active_record.schema_format = :sql\n\n    # Enable the asset pipeline\n    config.assets.enabled = true\n\n    # Version of your assets, change this if you want to expire all your assets\n    config.assets.version = '1.0'\n    \n    config.secret_key_base = \"some super secret\"\n  end\nend\n\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/boot.rb",
    "content": "require 'rubygems'\ngemfile = File.expand_path('../../../../Gemfile', __FILE__)\n\nif File.exist?(gemfile)\n  ENV['BUNDLE_GEMFILE'] = gemfile\n  require 'bundler'\n  Bundler.setup\nend\n\n$:.unshift File.expand_path('../../../../lib', __FILE__)"
  },
  {
    "path": "components/teaser/spec/dummy/config/database.yml",
    "content": "development:\n  adapter: sqlite3\n  database: db/development.sqlite3\n  pool: 5\n  timeout: 5000\n\ntest:\n  adapter: sqlite3\n  database: db/test.sqlite3\n  pool: 5\n  timeout: 5000\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/environment.rb",
    "content": "# Load the rails application\nrequire File.expand_path('../application', __FILE__)\n\n# Initialize the rails application\nDummy::Application.initialize!\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/environments/development.rb",
    "content": "Dummy::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # In the development environment your application's code is reloaded on\n  # every request. This slows down response time but is perfect for development\n  # since you don't have to restart the web server when you make code changes.\n  config.cache_classes = false\n\n  # Show full error reports and disable caching\n  config.consider_all_requests_local       = true\n  config.action_controller.perform_caching = false\n\n  # Don't care if the mailer can't send\n  config.action_mailer.raise_delivery_errors = false\n\n  # Print deprecation notices to the Rails logger\n  config.active_support.deprecation = :log\n\n  # Only use best-standards-support built into browsers\n  config.action_dispatch.best_standards_support = :builtin\n\n  # Do not compress assets\n  config.assets.compress = false\n\n  # Expands the lines which load the assets\n  config.assets.debug = true\n  \n  config.eager_load = false\nend\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/environments/production.rb",
    "content": "Dummy::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # Code is not reloaded between requests\n  config.cache_classes = true\n\n  # Full error reports are disabled and caching is turned on\n  config.consider_all_requests_local       = false\n  config.action_controller.perform_caching = true\n\n  # Disable Rails's static asset server (Apache or nginx will already do this)\n  config.serve_static_assets = false\n\n  # Compress JavaScripts and CSS\n  config.assets.compress = true\n\n  # Don't fallback to assets pipeline if a precompiled asset is missed\n  config.assets.compile = false\n\n  # Generate digests for assets URLs\n  config.assets.digest = true\n\n  # Defaults to nil and saved in location specified by config.assets.prefix\n  # config.assets.manifest = YOUR_PATH\n\n  # Specifies the header that your server uses for sending files\n  # config.action_dispatch.x_sendfile_header = \"X-Sendfile\" # for apache\n  # config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for nginx\n\n  # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.\n  # config.force_ssl = true\n\n  # See everything in the log (default is :info)\n  # config.log_level = :debug\n\n  # Prepend all log lines with the following tags\n  # config.log_tags = [ :subdomain, :uuid ]\n\n  # Use a different logger for distributed setups\n  # config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new)\n\n  # Use a different cache store in production\n  # config.cache_store = :mem_cache_store\n\n  # Enable serving of images, stylesheets, and JavaScripts from an asset server\n  # config.action_controller.asset_host = \"http://assets.example.com\"\n\n  # Precompile additional assets (application.js, application.css, and all non-JS/CSS are already added)\n  # config.assets.precompile += %w( search.js )\n\n  # Disable delivery errors, bad email addresses will be ignored\n  # config.action_mailer.raise_delivery_errors = false\n\n  # Enable threaded mode\n  # config.threadsafe!\n\n  # Enable locale fallbacks for I18n (makes lookups for any locale fall back to\n  # the I18n.default_locale when a translation can not be found)\n  config.i18n.fallbacks = true\n\n  # Send deprecation notices to registered listeners\n  config.active_support.deprecation = :notify\n\n  config.eager_load = true\nend\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/environments/test.rb",
    "content": "Dummy::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # The test environment is used exclusively to run your application's\n  # test suite. You never need to work with it otherwise. Remember that\n  # your test database is \"scratch space\" for the test suite and is wiped\n  # and recreated between test runs. Don't rely on the data there!\n  config.cache_classes = true\n\n  # Configure static asset server for tests with Cache-Control for performance\n  config.serve_static_assets = true\n  config.static_cache_control = \"public, max-age=3600\"\n\n  # Show full error reports and disable caching\n  config.consider_all_requests_local       = true\n  config.action_controller.perform_caching = false\n\n  # Raise exceptions instead of rendering exception templates\n  config.action_dispatch.show_exceptions = false\n\n  # Disable request forgery protection in test environment\n  config.action_controller.allow_forgery_protection    = false\n\n  # Tell Action Mailer not to deliver emails to the real world.\n  # The :test delivery method accumulates sent emails in the\n  # ActionMailer::Base.deliveries array.\n  config.action_mailer.delivery_method = :test\n\n  # Print deprecation notices to the stderr\n  config.active_support.deprecation = :stderr\n\n  config.eager_load = false\nend\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/initializers/backtrace_silencers.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces.\n# Rails.backtrace_cleaner.add_silencer { |line| line =~ /my_noisy_library/ }\n\n# You can also remove all the silencers if you're trying to debug a problem that might stem from framework code.\n# Rails.backtrace_cleaner.remove_silencers!\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/initializers/inflections.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Add new inflection rules using the following format\n# (all these examples are active by default):\n# ActiveSupport::Inflector.inflections do |inflect|\n#   inflect.plural /^(ox)$/i, '\\1en'\n#   inflect.singular /^(ox)en/i, '\\1'\n#   inflect.irregular 'person', 'people'\n#   inflect.uncountable %w( fish sheep )\n# end\n#\n# These inflection rules are supported but not enabled by default:\n# ActiveSupport::Inflector.inflections do |inflect|\n#   inflect.acronym 'RESTful'\n# end\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/initializers/mime_types.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Add new mime types for use in respond_to blocks:\n# Mime::Type.register \"text/richtext\", :rtf\n# Mime::Type.register_alias \"text/html\", :iphone\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/initializers/secret_token.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Your secret key for verifying the integrity of signed cookies.\n# If you change this key, all old signed cookies will become invalid!\n# Make sure the secret is at least 30 characters and all random,\n# no regular words or you'll be exposed to dictionary attacks.\nDummy::Application.config.secret_token = '38740bca001ba4e3a23cc52b7774f35821467eab796e2a0c3fb202d083b9d995d049a1788ae3091e08ad55656852e75a08f42858e7bf03b147db2e18bf4bc94e'\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/initializers/session_store.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\nDummy::Application.config.session_store :cookie_store, key: '_dummy_session'\n\n# Use the database for sessions instead of the cookie-based default,\n# which shouldn't be used to store highly confidential information\n# (create the session table with \"rails generate session_migration\")\n# Dummy::Application.config.session_store :active_record_store\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/initializers/wrap_parameters.rb",
    "content": "# Be sure to restart your server when you modify this file.\n#\n# This file contains settings for ActionController::ParamsWrapper which\n# is enabled by default.\n\n# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.\nActiveSupport.on_load(:action_controller) do\n  wrap_parameters format: [:json]\nend\n\n# Disable root element in JSON by default.\nActiveSupport.on_load(:active_record) do\n  self.include_root_in_json = false\nend\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/locales/en.yml",
    "content": "# Sample localization file for English. Add more files in this directory for other locales.\n# See https://github.com/svenfuchs/rails-i18n/tree/master/rails%2Flocale for starting points.\n\nen:\n  hello: \"Hello world\"\n"
  },
  {
    "path": "components/teaser/spec/dummy/config/routes.rb",
    "content": "Rails.application.routes.draw do\n  mount Teaser::Engine => \"/teaser\"\nend\n"
  },
  {
    "path": "components/teaser/spec/dummy/config.ru",
    "content": "# This file is used by Rack-based servers to start the application.\n\nrequire ::File.expand_path('../config/environment',  __FILE__)\nrun Dummy::Application\n"
  },
  {
    "path": "components/teaser/spec/dummy/db/schema.rb",
    "content": "# encoding: UTF-8\n# This file is auto-generated from the current state of the database. Instead\n# of editing this file, please use the migrations feature of Active Record to\n# incrementally modify your database, and then regenerate this schema definition.\n#\n# Note that this schema.rb definition is the authoritative source for your\n# database schema. If you need to create the application database on another\n# system, you should be using db:schema:load, not running all the migrations\n# from scratch. The latter is a flawed and unsustainable approach (the more migrations\n# you'll amass, the slower it'll run and the greater likelihood for issues).\n#\n# It's strongly recommended that you check this file into your version control system.\n\nActiveRecord::Schema.define(version: 20130403220851) do\n\n  create_table \"email_signup_entries\", force: true do |t|\n    t.string   \"email\"\n    t.datetime \"created_at\", null: false\n    t.datetime \"updated_at\", null: false\n  end\n\n  create_table \"event_counter_counts\", force: true do |t|\n    t.string  \"object_identifier\"\n    t.string  \"event_identifier\"\n    t.integer \"count\",             default: 0\n  end\n\nend\n"
  },
  {
    "path": "components/teaser/spec/dummy/lib/assets/.gitkeep",
    "content": ""
  },
  {
    "path": "components/teaser/spec/dummy/log/.gitkeep",
    "content": ""
  },
  {
    "path": "components/teaser/spec/dummy/public/404.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>The page you were looking for doesn't exist (404)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/404.html -->\n  <div class=\"dialog\">\n    <h1>The page you were looking for doesn't exist.</h1>\n    <p>You may have mistyped the address or the page may have moved.</p>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "components/teaser/spec/dummy/public/422.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>The change you wanted was rejected (422)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/422.html -->\n  <div class=\"dialog\">\n    <h1>The change you wanted was rejected.</h1>\n    <p>Maybe you tried to change something you didn't have access to.</p>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "components/teaser/spec/dummy/public/500.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>We're sorry, but something went wrong (500)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/500.html -->\n  <div class=\"dialog\">\n    <h1>We're sorry, but something went wrong.</h1>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "components/teaser/spec/dummy/script/rails",
    "content": "#!/usr/bin/env ruby\n# This command will automatically be run when you run \"rails\" with Rails 3 gems installed from the root of your application.\n\nAPP_PATH = File.expand_path('../../config/application',  __FILE__)\nrequire File.expand_path('../../config/boot',  __FILE__)\nrequire 'rails/commands'\n"
  },
  {
    "path": "components/teaser/spec/dummy/teaser_test",
    "content": ""
  },
  {
    "path": "components/teaser/spec/features/signing_up_for_updates_spec.rb",
    "content": "require \"request_spec_helper\"\n\nfeature \"Signing up for tnbt updates\", %q{\n  In order to stay informed about the next big thing\n  As a person\n  I want to be able to sign up to updates\n} do\n\n  background do\n    EmailSignup::Entry.delete_all\n  end\n\n  scenario \"sign up\", js: \"true\" do\n    visit teaser.root_path\n\n    expect {\n      fill_in \"signup\", with: \"stephan@pivotallabs.com\"\n      press_key_on_selector(13, \"#signup\")\n\n      page.should have_content \"Thanks for signing up!\"\n    }.to change(EmailSignup::Entry, :count).from(0).to(1)\n  end\nend"
  },
  {
    "path": "components/teaser/spec/javascripts/helpers/mock-ajax.js",
    "content": "/*\n\nJasmine-Ajax : a set of helpers for testing AJAX requests under the Jasmine\nBDD framework for JavaScript.\n\nhttp://github.com/pivotal/jasmine-ajax\n\nJasmine Home page: http://pivotal.github.com/jasmine\n\nCopyright (c) 2008-2013 Pivotal Labs\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\n*/\n\n(function() {\n  function extend(destination, source) {\n    for (var property in source) {\n      destination[property] = source[property];\n    }\n    return destination;\n  }\n\n  function MockAjax(global) {\n    var requestTracker = new RequestTracker(),\n      stubTracker = new StubTracker(),\n      realAjaxFunction = global.XMLHttpRequest,\n      mockAjaxFunction = fakeRequest(requestTracker, stubTracker);\n\n    this.install = function() {\n      global.XMLHttpRequest = mockAjaxFunction;\n    };\n\n    this.uninstall = function() {\n      global.XMLHttpRequest = realAjaxFunction;\n    };\n\n    this.stubRequest = function(url) {\n      var stub = new RequestStub(url);\n      stubTracker.addStub(stub);\n      return stub;\n    };\n\n    this.withMock = function(closure) {\n      this.install();\n      try {\n        closure();\n      } finally {\n        this.uninstall();\n      }\n    };\n\n    this.requests = requestTracker;\n    this.stubs = stubTracker;\n  }\n\n  function StubTracker() {\n    var stubs = [];\n\n    this.addStub = function(stub) {\n      stubs.push(stub);\n    };\n\n    this.reset = function() {\n      stubs = [];\n    };\n\n    this.findStub = function(url) {\n      for (var i = stubs.length - 1; i >= 0; i--) {\n        var stub = stubs[i];\n        if (stub.url === url) {\n          return stub;\n        }\n      }\n    };\n  }\n\n  function fakeRequest(requestTracker, stubTracker) {\n    function FakeXMLHttpRequest() {\n      requestTracker.track(this);\n    }\n\n    extend(FakeXMLHttpRequest.prototype, window.XMLHttpRequest);\n    extend(FakeXMLHttpRequest.prototype, {\n      requestHeaders: {},\n\n      open: function() {\n        this.method = arguments[0];\n        this.url = arguments[1];\n        this.username = arguments[3];\n        this.password = arguments[4];\n        this.readyState = 1;\n      },\n\n      setRequestHeader: function(header, value) {\n        this.requestHeaders[header] = value;\n      },\n\n      abort: function() {\n        this.readyState = 0;\n      },\n\n      readyState: 0,\n\n      onload: function() {\n      },\n\n      onreadystatechange: function(isTimeout) {\n      },\n\n      status: null,\n\n      send: function(data) {\n        this.params = data;\n        this.readyState = 2;\n\n        var stub = stubTracker.findStub(this.url);\n        if (stub) {\n          this.response(stub);\n        }\n      },\n\n      data: function() {\n        var data = {};\n        if (typeof this.params !== 'string') { return data; }\n        var params = this.params.split('&');\n\n        for (var i = 0; i < params.length; ++i) {\n          var kv = params[i].replace(/\\+/g, ' ').split('=');\n          var key = decodeURIComponent(kv[0]);\n          data[key] = data[key] || [];\n          data[key].push(decodeURIComponent(kv[1]));\n          data[key].sort();\n        }\n        return data;\n      },\n\n      getResponseHeader: function(name) {\n        return this.responseHeaders[name];\n      },\n\n      getAllResponseHeaders: function() {\n        var responseHeaders = [];\n        for (var i in this.responseHeaders) {\n          if (this.responseHeaders.hasOwnProperty(i)) {\n            responseHeaders.push(i + ': ' + this.responseHeaders[i]);\n          }\n        }\n        return responseHeaders.join('\\r\\n');\n      },\n\n      responseText: null,\n\n      response: function(response) {\n        this.status = response.status;\n        this.responseText = response.responseText || \"\";\n        this.readyState = 4;\n        this.responseHeaders = response.responseHeaders ||\n          {\"Content-type\": response.contentType || \"application/json\" };\n\n        this.onload();\n        this.onreadystatechange();\n      },\n\n      responseTimeout: function() {\n        this.readyState = 4;\n        clock.tick(30000);\n        this.onreadystatechange('timeout');\n      }\n    });\n\n    return FakeXMLHttpRequest;\n  }\n\n  function RequestTracker() {\n    var requests = [];\n\n    this.track = function(request) {\n      requests.push(request);\n    };\n\n    this.first = function() {\n      return requests[0];\n    };\n\n    this.count = function() {\n      return requests.length;\n    };\n\n    this.reset = function() {\n      requests = [];\n    };\n\n    this.mostRecent = function() {\n      return requests[requests.length - 1];\n    };\n\n    this.at = function(index) {\n      return requests[index];\n    };\n  }\n\n  function RequestStub(url) {\n    this.url = url;\n\n    this.andReturn = function(options) {\n      this.status = options.status || 200;\n\n      this.contentType = options.contentType;\n      this.responseText = options.responseText;\n    };\n  }\n\n  if (typeof window === \"undefined\" && typeof exports === \"object\") {\n    exports.MockAjax = MockAjax;\n    jasmine.Ajax = new MockAjax(exports);\n  } else {\n    window.MockAjax = MockAjax;\n    jasmine.Ajax = new MockAjax(window);\n  }\n}());\n"
  },
  {
    "path": "components/teaser/spec/javascripts/support/jasmine.yml",
    "content": "# src_files\n#\n# Return an array of filepaths relative to src_dir to include before jasmine specs.\n# Default: []\n#\n# EXAMPLE:\n#\n# src_files:\n#   - lib/source1.js\n#   - lib/source2.js\n#   - dist/**/*.js\n#\nsrc_files:\n  - assets/teaser/application.js\n\n# stylesheets\n#\n# Return an array of stylesheet filepaths relative to src_dir to include before jasmine specs.\n# Default: []\n#\n# EXAMPLE:\n#\n# stylesheets:\n#   - css/style.css\n#   - stylesheets/*.css\n#\nstylesheets:\n  - stylesheets/teaster/**/*.css\n\n# helpers\n#\n# Return an array of filepaths relative to spec_dir to include before jasmine specs.\n# Default: [\"helpers/**/*.js\"]\n#\n# EXAMPLE:\n#\n# helpers:\n#   - helpers/**/*.js\n#\nhelpers:\n  - helpers/**/*.js\n  - helpers/mock-ajax.js\n\n# spec_files\n#\n# Return an array of filepaths relative to spec_dir to include.\n# Default: [\"**/*[sS]pec.js\"]\n#\n# EXAMPLE:\n#\n# spec_files:\n#   - **/*[sS]pec.js\n#\nspec_files:\n  - '**/*[sS]pec.js'\n\n# src_dir\n#\n# Source directory path. Your src_files must be returned relative to this path. Will use root if left blank.\n# Default: project root\n#\n# EXAMPLE:\n#\n# src_dir: public\n#\nsrc_dir:\n  - sources/**/*.js\n\n# spec_dir\n#\n# Spec directory path. Your spec_files must be returned relative to this path.\n# Default: spec/javascripts\n#\n# EXAMPLE:\n#\n# spec_dir: spec/javascripts\n#\nspec_dir: spec/javascripts\n"
  },
  {
    "path": "components/teaser/spec/javascripts/teaser/signup_spec.js",
    "content": "describe(\"Teaser.SignUp\", function () {\n    describe(\"#initialize\", function () {\n        it(\"should transform the given parameters into variables on the object\", function () {\n            $(\"#jasmine_content\").html(\"<p class='input'>within p</p><div class='result'>within div</div>\");\n            var signUp = new Teaser.SignUp;\n            signUp.initialize(\".input\", \".result\", \"signUpEndpoint\");\n\n            expect(signUp.signUpEndpoint).toEqual(\"signUpEndpoint\");\n            expect(signUp.$inputElement.html()).toEqual(\"within p\");\n            expect(signUp.$resultElement.html()).toEqual(\"within div\");\n        });\n\n        it(\"should register signUpIfSubmitted on keydowns in the input\", function () {\n            var signUpIfSubmitted = spyOn(Teaser.SignUp.prototype, \"signUpIfSubmitted\");\n\n            $(\"#jasmine_content\").html(\"<p class='input'>within p</p><div class='result'>within div</div>\");\n            var signUp = new Teaser.SignUp;\n            signUp.initialize(\".input\", \".result\", \"signUpEndpoint\");\n\n            $(\".input\").trigger(\"keydown\")\n\n            expect(signUpIfSubmitted).toHaveBeenCalled();\n        });\n    });\n\n    describe(\"#signUp\", function () {\n        var handleSubmissionResult, request;\n        var callAjax = function () {\n            jasmine.Ajax.install();\n\n            handleSubmissionResult = spyOn(Teaser.SignUp.prototype, \"handleSubmissionResult\");\n\n            var signUp = new Teaser.SignUp;\n            signUp.signUpEndpoint = \"signUpEndpoint\";\n            signUp.$inputElement = {val:function () {\n                return \"value of input\"\n            }}\n\n            signUp.signUp();\n\n            request = jasmine.Ajax.requests.mostRecent();\n        }\n\n        it(\"should post the value of the input element to the signUpEndpoint\", function () {\n\t\t\tpending(\"don't yet know how to do this test with the new jasmine API\")\n            var post = spyOn($, \"post\").andCallThrough();\n\n            callAjax();\n\n            expect(post).toHaveBeenCalledWith(\"signUpEndpoint\", { new_sign_up_entry:\"value of input\" }, jasmine.any(Function));\n        });\n\n        it(\"should call handleSubmissionResult with success if the ajax call is successful\", function () {\n            callAjax();\n            request.response({status:200, responseText:\"{}\"});\n\n            expect(handleSubmissionResult).toHaveBeenCalledWith(\"success\", {});\n        });\n\n        it(\"should call handleSubmissionResult with error if the ajax call is unsuccessful\", function () {\n            callAjax();\n            request.response({status:400, responseText:\"\"});\n\n            expect(handleSubmissionResult).toHaveBeenCalledWith(\"error\", jasmine.any(Object));\n        });\n    });\n\n    describe(\"#signUpIfSubmitted\", function () {\n        var signUp, event;\n        beforeEach(function () {\n            signUp = new Teaser.SignUp;\n            spyOn(signUp, \"signUp\");\n\n            event = jQuery.Event(\"keydown\");\n        });\n\n        describe(\"when the key pressed is Enter\", function () {\n            beforeEach(function () {\n                event.keyCode = 13;\n            });\n\n            it(\"should prevent default\", function () {\n                spyOn(event, \"preventDefault\");\n                signUp.signUpIfSubmitted(event);\n                expect(event.preventDefault).toHaveBeenCalled();\n            });\n\n            it(\"should call signUp\", function () {\n                signUp.signUpIfSubmitted(event);\n                expect(signUp.signUp).toHaveBeenCalled();\n            });\n        });\n\n        describe(\"when the key pressed is not Enter\", function () {\n            beforeEach(function () {\n                event.keyCode = 14;\n            });\n\n            it(\"should not prevent default\", function () {\n                spyOn(event, \"preventDefault\");\n                signUp.signUpIfSubmitted(event);\n                expect(event.preventDefault).not.toHaveBeenCalled();\n            });\n\n            it(\"should not call signUp\", function () {\n                signUp.signUpIfSubmitted(event);\n                expect(signUp.signUp).not.toHaveBeenCalled();\n            });\n        });\n    });\n\n    describe(\"handleSubmissionResult\", function () {\n        var signUp;\n\n        beforeEach(function () {\n            $(\"#jasmine_content\").html(\"<div class='result'></div>\");\n            signUp = new Teaser.SignUp;\n            signUp.$resultElement = $(\".result\");\n        });\n\n        it(\"should prepend the result's responseText to the $resultElement\", function () {\n            signUp.handleSubmissionResult(\"success_class\", {responseText: \"this was a success\"});\n            expect(signUp.$resultElement.html()).toEqual('<p class=\"success_class\">this was a success</p>');\n        });\n\n        it(\"should prepend the result to the $resultElement (if there is no responseText)\", function () {\n            signUp.handleSubmissionResult(\"success_class\", \"this was also a success\");\n            expect(signUp.$resultElement.html()).toEqual('<p class=\"success_class\">this was also a success</p>');\n        });\n    });\n});"
  },
  {
    "path": "components/teaser/spec/request_spec_helper.rb",
    "content": "ENV[\"RAILS_ENV\"] ||= 'test'\nrequire File.expand_path(\"../dummy/config/environment\", __FILE__)\n\nrequire 'rspec/rails'\n\nrequire 'capybara/rspec'\nrequire 'capybara/poltergeist'\nCapybara.javascript_driver = :poltergeist\n\nDir[Teaser::Engine.root.join(\"spec/support/**/*.rb\")].each {|f| require f}\n\nRSpec.configure do |config|\n  config.use_transactional_fixtures = false\n  config.infer_base_class_for_anonymous_controllers = false\n  config.order = \"random\"\n  config.include RequestSpecHelpers\n  config.include Capybara::DSL\nend\n"
  },
  {
    "path": "components/teaser/spec/spec_helper.rb",
    "content": "ENV[\"RAILS_ENV\"] ||= 'test'\nrequire File.expand_path(\"../dummy/config/environment\", __FILE__)\n\nrequire 'rspec/rails'\nrequire 'shoulda-matchers'\nrequire 'event_counter/test_helper'\n\nDir[Teaser::Engine.root.join(\"spec/support/**/*.rb\")].each {|f| require f}\n\nRSpec.configure do |config|\n  config.use_transactional_fixtures = true\n  config.infer_base_class_for_anonymous_controllers = false\n  config.order = \"random\"\nend\n"
  },
  {
    "path": "components/teaser/spec/support/request_spec_helpers.rb",
    "content": "module RequestSpecHelpers\n  def press_key_on_selector(key, selector)\n    page.driver.execute_script(\"var e = $.Event('keydown', { keyCode: #{key} }); $('#{selector}').trigger(e);\")\n  end\nend"
  },
  {
    "path": "components/teaser/teaser.gemspec",
    "content": "$:.push File.expand_path(\"../lib\", __FILE__)\n\n# Maintain your gem\"s version:\nrequire \"teaser/version\"\n\n# Describe your gem and declare its dependencies:\nGem::Specification.new do |s|\n  s.name        = \"teaser\"\n  s.version     = Teaser::VERSION\n  s.authors     = [\"Stephan Hagemann\"]\n  s.email       = [\"stephan.hagemann@gmail.com\"]\n  s.summary     = \"Teaser gem\"\n  s.description = \"Teaser gem\"\n\n  s.files = Dir[\"{app,config,db,lib}/**/*\"] + [\"MIT-LICENSE\", \"Rakefile\", \"README.rdoc\"]\n\n  s.add_dependency \"rails\", \"4.1.8\"\n  s.add_dependency \"haml-rails\", \"0.5.3\"\n  s.add_dependency \"sass-rails\", \"4.0.1\"\n  s.add_dependency \"jquery-rails\", \"3.1.0\"\n\n  s.add_dependency \"event_counter\"\n  s.add_dependency \"annoyance\"\n  s.add_dependency \"email_signup\"\n\n  s.add_development_dependency \"rspec-rails\", \"3.1.0\"\n  s.add_development_dependency \"capybara\", \"2.4.1\"\n  s.add_development_dependency \"shoulda-matchers\", \"2.7.0\"\n  s.add_development_dependency \"sqlite3\", \"1.3.9\"\n  s.add_development_dependency \"poltergeist\", \"1.5.1\"\n  s.add_development_dependency \"jasmine\", \"1.3.2\"\nend\n"
  },
  {
    "path": "components/teaser/test.sh",
    "content": "#!/bin/bash\n\nexit_code=0\n\necho \"*** Running teaser engine specs\"\nbundle install  --jobs=3 --retry=3 | grep Installing\nbundle exec rake db:create \nbundle exec rake db:migrate\nRAILS_ENV=test bundle exec rake db:create \nRAILS_ENV=test bundle exec rake db:migrate\nbundle exec rspec spec/controllers\nexit_code+=$?\n\necho \"*** Running teaser engine request specs\"\nbundle exec rspec spec/features\nexit_code+=$?\n\necho \"*** Running teaser engine javascript specs\"\nbundle exec rake app:jasmine:ci\nexit_code+=$?\n\nexit $exit_code\n"
  },
  {
    "path": "config/application.rb",
    "content": "require File.expand_path('../boot', __FILE__)\n\n# Pick the frameworks you want:\n# require \"active_record/railtie\"\nrequire \"action_controller/railtie\"\nrequire \"action_mailer/railtie\"\n# require \"active_resource/railtie\"\nrequire \"sprockets/railtie\"\n#require \"rails/test_unit/railtie\"\n\nif defined?(Bundler)\n  # If you precompile assets before deploying to production, use this line\n  Bundler.require(*Rails.groups(:assets => %w(development test)))\n  # If you want your assets lazily compiled in production, use this line\n  # Bundler.require(:default, :assets, Rails.env)\nend\n\nmodule TheNextBigThing\n  class Application < Rails::Application\n\n    # Settings in config/environments/* take precedence over those specified here.\n    # Application configuration should go into files in config/initializers\n    # -- all .rb files in that directory are automatically loaded.\n\n    # Custom directories with classes and modules you want to be autoloadable.\n    # config.autoload_paths += %W(#{config.root}/extras)\n\n    # Only load the plugins named here, in the order given (default is alphabetical).\n    # :all can be used as a placeholder for all plugins not explicitly named.\n    # config.plugins = [ :exception_notification, :ssl_requirement, :all ]\n\n    # Activate observers that should always be running.\n    # config.active_record.observers = :cacher, :garbage_collector, :forum_observer\n\n    # Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.\n    # Run \"rake -D time\" for a list of tasks for finding time zone names. Default is UTC.\n    # config.time_zone = 'Central Time (US & Canada)'\n\n    # The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.\n    # config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]\n    # config.i18n.default_locale = :de\n\n    # Configure the default encoding used in templates for Ruby 1.9.\n    config.encoding = \"utf-8\"\n\n    # Configure sensitive parameters which will be filtered from the log file.\n    config.filter_parameters += [:password]\n\n    # Enable escaping HTML in JSON.\n    config.active_support.escape_html_entities_in_json = true\n\n    # Use SQL instead of Active Record's schema dumper when creating the database.\n    # This is necessary if your schema can't be completely dumped by the schema dumper,\n    # like if you have constraints or database-specific column types\n    # config.active_record.schema_format = :sql\n\n    # Enforce whitelist mode for mass assignment.\n    # This will create an empty whitelist of attributes available for mass-assignment for all models\n    # in your app. As such, your models will need to explicitly whitelist or blacklist accessible\n    # parameters by using an attr_accessible or attr_protected declaration.\n    # config.active_record.whitelist_attributes = true\n\n    # Enable the asset pipeline\n    config.assets.enabled = true\n\n    # Version of your assets, change this if you want to expire all your assets\n    config.assets.version = '1.0'\n\n    #config.assets.initialize_on_precompile = false\n    \n    config.secret_key_base = \"some super secret\"\n  end\nend\n"
  },
  {
    "path": "config/boot.rb",
    "content": "require 'rubygems'\n\n# Set up gems listed in the Gemfile.\nENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)\n\nrequire 'bundler/setup' if File.exists?(ENV['BUNDLE_GEMFILE'])\n"
  },
  {
    "path": "config/database.yml",
    "content": "development:\n  adapter: sqlite3\n  database: db/development.sqlite3\n  pool: 5\n  timeout: 5000\n\ntest:\n  adapter: sqlite3\n  database: db/test.sqlite3\n  pool: 5\n  timeout: 5000\n"
  },
  {
    "path": "config/environment.rb",
    "content": "# Load the rails application\nrequire File.expand_path('../application', __FILE__)\n\n# Initialize the rails application\nTheNextBigThing::Application.initialize!\n"
  },
  {
    "path": "config/environments/development.rb",
    "content": "TheNextBigThing::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # In the development environment your application's code is reloaded on\n  # every request. This slows down response time but is perfect for development\n  # since you don't have to restart the web server when you make code changes.\n  config.cache_classes = false\n\n  # Show full error reports and disable caching\n  config.consider_all_requests_local       = true\n  config.action_controller.perform_caching = false\n\n  # Don't care if the mailer can't send\n  config.action_mailer.raise_delivery_errors = false\n\n  # Print deprecation notices to the Rails logger\n  config.active_support.deprecation = :log\n\n  # Only use best-standards-support built into browsers\n  config.action_dispatch.best_standards_support = :builtin\n\n  config.eager_load = false\nend\n"
  },
  {
    "path": "config/environments/production.rb",
    "content": "TheNextBigThing::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # Code is not reloaded between requests\n  config.cache_classes = true\n\n  # Full error reports are disabled and caching is turned on\n  config.consider_all_requests_local       = false\n  config.action_controller.perform_caching = true\n\n  # Disable Rails's static asset server (Apache or nginx will already do this)\n  config.serve_static_assets = false\n\n\n  # Specifies the header that your server uses for sending files\n  # config.action_dispatch.x_sendfile_header = \"X-Sendfile\" # for apache\n  # config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for nginx\n\n  # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.\n  # config.force_ssl = true\n\n  # See everything in the log (default is :info)\n  # config.log_level = :debug\n\n  # Prepend all log lines with the following tags\n  # config.log_tags = [ :subdomain, :uuid ]\n\n  # Use a different logger for distributed setups\n  # config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new)\n\n  # Use a different cache store in production\n  # config.cache_store = :mem_cache_store\n\n  # Enable serving of images, stylesheets, and JavaScripts from an asset server\n  # config.action_controller.asset_host = \"http://assets.example.com\"\n\n\n  # Disable delivery errors, bad email addresses will be ignored\n  # config.action_mailer.raise_delivery_errors = false\n\n  # Enable threaded mode\n  # config.threadsafe!\n\n  # Enable locale fallbacks for I18n (makes lookups for any locale fall back to\n  # the I18n.default_locale when a translation can not be found)\n  config.i18n.fallbacks = true\n\n  # Send deprecation notices to registered listeners\n  config.active_support.deprecation = :notify\n\n  config.eager_load = true\nend\n"
  },
  {
    "path": "config/environments/test.rb",
    "content": "TheNextBigThing::Application.configure do\n  # Settings specified here will take precedence over those in config/application.rb\n\n  # The test environment is used exclusively to run your application's\n  # test suite. You never need to work with it otherwise. Remember that\n  # your test database is \"scratch space\" for the test suite and is wiped\n  # and recreated between test runs. Don't rely on the data there!\n  config.cache_classes = true\n\n  # Configure static asset server for tests with Cache-Control for performance\n  config.serve_static_assets = true\n  config.static_cache_control = \"public, max-age=3600\"\n\n  # Show full error reports and disable caching\n  config.consider_all_requests_local       = true\n  config.action_controller.perform_caching = false\n\n  # Raise exceptions instead of rendering exception templates\n  config.action_dispatch.show_exceptions = false\n\n  # Disable request forgery protection in test environment\n  config.action_controller.allow_forgery_protection    = false\n\n  # Tell Action Mailer not to deliver emails to the real world.\n  # The :test delivery method accumulates sent emails in the\n  # ActionMailer::Base.deliveries array.\n  config.action_mailer.delivery_method = :test\n\n\n  # Print deprecation notices to the stderr\n  config.active_support.deprecation = :stderr\n\n  config.eager_load = false\nend\n"
  },
  {
    "path": "config/initializers/backtrace_silencers.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces.\n# Rails.backtrace_cleaner.add_silencer { |line| line =~ /my_noisy_library/ }\n\n# You can also remove all the silencers if you're trying to debug a problem that might stem from framework code.\n# Rails.backtrace_cleaner.remove_silencers!\n"
  },
  {
    "path": "config/initializers/inflections.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Add new inflection rules using the following format\n# (all these examples are active by default):\n# ActiveSupport::Inflector.inflections do |inflect|\n#   inflect.plural /^(ox)$/i, '\\1en'\n#   inflect.singular /^(ox)en/i, '\\1'\n#   inflect.irregular 'person', 'people'\n#   inflect.uncountable %w( fish sheep )\n# end\n#\n# These inflection rules are supported but not enabled by default:\n# ActiveSupport::Inflector.inflections do |inflect|\n#   inflect.acronym 'RESTful'\n# end\n"
  },
  {
    "path": "config/initializers/mime_types.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Add new mime types for use in respond_to blocks:\n# Mime::Type.register \"text/richtext\", :rtf\n# Mime::Type.register_alias \"text/html\", :iphone\n"
  },
  {
    "path": "config/initializers/secret_token.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\n# Your secret key for verifying the integrity of signed cookies.\n# If you change this key, all old signed cookies will become invalid!\n# Make sure the secret is at least 30 characters and all random,\n# no regular words or you'll be exposed to dictionary attacks.\nTheNextBigThing::Application.config.secret_token = 'f0a8e268c6f152a6a8a4833925366d511d62b85fa34098ed120238540e068c9578636785b920537a10c84bc0e512a6f6e0e782e6852971cabeacf96019a85c71'\n"
  },
  {
    "path": "config/initializers/session_store.rb",
    "content": "# Be sure to restart your server when you modify this file.\n\nTheNextBigThing::Application.config.session_store :cookie_store, key: '_the_next_big_thing_session'\n\n# Use the database for sessions instead of the cookie-based default,\n# which shouldn't be used to store highly confidential information\n# (create the session table with \"rails generate session_migration\")\n# TheNextBigThing::Application.config.session_store :active_record_store\n"
  },
  {
    "path": "config/initializers/wrap_parameters.rb",
    "content": "# Be sure to restart your server when you modify this file.\n#\n# This file contains settings for ActionController::ParamsWrapper which\n# is enabled by default.\n\n# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.\nActiveSupport.on_load(:action_controller) do\n  wrap_parameters format: [:json]\nend\n\n"
  },
  {
    "path": "config/locales/en.yml",
    "content": "# Sample localization file for English. Add more files in this directory for other locales.\n# See https://github.com/svenfuchs/rails-i18n/tree/master/rails%2Flocale for starting points.\n\nen:\n  hello: \"Hello world\"\n"
  },
  {
    "path": "config/routes.rb",
    "content": "TheNextBigThing::Application.routes.draw do\n  mount Teaser::Engine => \"/\"\nend\n"
  },
  {
    "path": "config.ru",
    "content": "# This file is used by Rack-based servers to start the application.\n\nrequire ::File.expand_path('../config/environment',  __FILE__)\nrun TheNextBigThing::Application\n"
  },
  {
    "path": "db/schema.rb",
    "content": "# encoding: UTF-8\n# This file is auto-generated from the current state of the database. Instead\n# of editing this file, please use the migrations feature of Active Record to\n# incrementally modify your database, and then regenerate this schema definition.\n#\n# Note that this schema.rb definition is the authoritative source for your\n# database schema. If you need to create the application database on another\n# system, you should be using db:schema:load, not running all the migrations\n# from scratch. The latter is a flawed and unsustainable approach (the more migrations\n# you'll amass, the slower it'll run and the greater likelihood for issues).\n#\n# It's strongly recommended that you check this file into your version control system.\n\nActiveRecord::Schema.define(version: 20130403220851) do\n\n  create_table \"email_signup_entries\", force: true do |t|\n    t.string   \"email\"\n    t.datetime \"created_at\", null: false\n    t.datetime \"updated_at\", null: false\n  end\n\n  create_table \"event_counter_counts\", force: true do |t|\n    t.string  \"object_identifier\"\n    t.string  \"event_identifier\"\n    t.integer \"count\",             default: 0\n  end\n\nend\n"
  },
  {
    "path": "db/seeds.rb",
    "content": "# This file should contain all the record creation needed to seed the database with its default values.\n# The data can then be loaded with the rake db:seed (or created alongside the db with db:setup).\n#\n# Examples:\n#\n#   cities = City.create([{ name: 'Chicago' }, { name: 'Copenhagen' }])\n#   Mayor.create(name: 'Emanuel', city: cities.first)\n"
  },
  {
    "path": "log/.gitkeep",
    "content": ""
  },
  {
    "path": "migrate_and_prepare_all.sh",
    "content": "#!/bin/bash\n\n[ -s \"$HOME/.rvm/scripts/rvm\" ] && . \"$HOME/.rvm/scripts/rvm\"\n\necho \"migrating teaser\"\ncd engines/teaser && rake db:migrate app:db:test:prepare && cd ../..\necho \"migrating wrapper rails app\"\nrake db:migrate db:test:prepare"
  },
  {
    "path": "public/404.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>The page you were looking for doesn't exist (404)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/404.html -->\n  <div class=\"dialog\">\n    <h1>The page you were looking for doesn't exist.</h1>\n    <p>You may have mistyped the address or the page may have moved.</p>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "public/422.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>The change you wanted was rejected (422)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/422.html -->\n  <div class=\"dialog\">\n    <h1>The change you wanted was rejected.</h1>\n    <p>Maybe you tried to change something you didn't have access to.</p>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "public/500.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n  <title>We're sorry, but something went wrong (500)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/500.html -->\n  <div class=\"dialog\">\n    <h1>We're sorry, but something went wrong.</h1>\n  </div>\n</body>\n</html>\n"
  },
  {
    "path": "public/robots.txt",
    "content": "# See http://www.robotstxt.org/wc/norobots.html for documentation on how to use the robots.txt file\n#\n# To ban all spiders from the entire site uncomment the next two lines:\n# User-Agent: *\n# Disallow: /\n"
  },
  {
    "path": "script/rails",
    "content": "#!/usr/bin/env ruby\n# This command will automatically be run when you run \"rails\" with Rails 3 gems installed from the root of your application.\n\nAPP_PATH = File.expand_path('../../config/application',  __FILE__)\nrequire File.expand_path('../../config/boot',  __FILE__)\nrequire 'rails/commands'\n"
  },
  {
    "path": "spec/features/home_page_spec.rb",
    "content": "require \"spec_helper\"\n\nfeature \"The Next Big Thing Homepage\", %q{\n  In order to get informed about the next big thing\n  As a person\n  I want to be able to read about nothing definite about it and sign up for more info\n} do\n\n  scenario \"The Homepage\" do\n    visit \"/\"\n    page.should have_content(\"The Next Big Thing\")\n    page.should have_content(\"Find nothing out about it right here!\")\n  end\nend"
  },
  {
    "path": "spec/fixtures/.gitkeep",
    "content": ""
  },
  {
    "path": "spec/spec_helper.rb",
    "content": "ENV[\"RAILS_ENV\"] ||= 'test'\nrequire File.expand_path(\"../../config/environment\", __FILE__)\nrequire 'rspec/rails'\nrequire 'rspec/autorun'\nrequire 'capybara/rspec'\n\nDir[Rails.root.join(\"spec/support/**/*.rb\")].each {|f| require f}\n\nRSpec.configure do |config|\n  config.order = \"random\"\nend\n"
  },
  {
    "path": "test.sh",
    "content": "#!/bin/bash\n\nexit_code=0\n\necho \"*** Running container app specs\"\nbundle install  --jobs=3 --retry=3 | grep Installing\nbundle exec rake db:create db:migrate #don't remove this line. If only run in test our schema.rb doesn't include required engine's migrations\nRAILS_ENV=test bundle exec rake db:create db:migrate\nbundle exec rspec spec\nexit_code+=$?\n\nexit $exit_code\n\n"
  },
  {
    "path": "vendor/assets/javascripts/.gitkeep",
    "content": ""
  },
  {
    "path": "vendor/assets/stylesheets/.gitkeep",
    "content": ""
  },
  {
    "path": "vendor/plugins/.gitkeep",
    "content": ""
  }
]