├── rack ├── test │ ├── .bacon │ ├── multipart │ │ ├── file1.txt │ │ ├── binary │ │ ├── semicolon │ │ ├── content_type_and_no_filename │ │ ├── filename_with_escaped_quotes │ │ ├── filename_with_unescaped_quotes │ │ ├── ie │ │ ├── none │ │ ├── filename_with_percent_escaped_quotes │ │ ├── empty │ │ ├── filename_with_unescaped_percentages2 │ │ ├── filename_with_unescaped_percentages3 │ │ ├── content_id │ │ ├── nested │ │ ├── filename_with_unescaped_percentages │ │ └── filename_and_modification_param │ ├── static │ │ ├── index.html │ │ └── another │ │ │ └── index.html │ ├── rackup │ │ └── .gitignore │ ├── cgi │ │ ├── assets │ │ │ ├── index.html │ │ │ ├── folder │ │ │ │ └── test.js │ │ │ ├── fonts │ │ │ │ └── font.eot │ │ │ ├── images │ │ │ │ └── image.png │ │ │ ├── javascripts │ │ │ │ └── app.js │ │ │ └── stylesheets │ │ │ │ └── app.css │ │ ├── test+directory │ │ │ └── test+file │ │ ├── sample_rackup.ru │ │ ├── test.ru │ │ ├── rackup_stub.rb │ │ ├── test.fcgi │ │ └── test │ ├── builder │ │ ├── line.ru │ │ ├── options.ru │ │ ├── comment.ru │ │ ├── anything.rb │ │ └── end.ru │ ├── registering_handler │ │ └── rack │ │ │ └── handler │ │ │ └── registering_myself.rb │ └── unregistered_handler │ │ └── rack │ │ └── handler │ │ ├── unregistered.rb │ │ └── unregistered_long_one.rb ├── bin │ └── rackup ├── contrib │ └── rack.png ├── example │ ├── lobster.ru │ └── protectedlobster.ru ├── .gitignore ├── lib │ └── rack │ │ ├── handler │ │ ├── evented_mongrel.rb │ │ └── swiftiplied_mongrel.rb │ │ └── version.rb └── Gemfile ├── .ruby-version ├── Gemfile.1.8 ├── Gemfile.2.3 ├── Gemfile.2.5 ├── Gemfile.2.7 ├── Gemfile.3.1 ├── Gemfile.3.3 ├── railties ├── configs │ ├── empty.log │ ├── locales │ │ └── en.yml │ └── initializers │ │ └── mime_types.rb ├── html │ ├── favicon.ico │ ├── images │ │ └── rails.png │ ├── javascripts │ │ └── application.js │ └── robots.txt ├── test │ ├── fixtures │ │ ├── public │ │ │ ├── index.html │ │ │ └── foo │ │ │ │ ├── bar.html │ │ │ │ └── index.html │ │ ├── plugins │ │ │ ├── alternate │ │ │ │ └── a │ │ │ │ │ ├── lib │ │ │ │ │ └── .gitignore │ │ │ │ │ └── generators │ │ │ │ │ └── a_generator │ │ │ │ │ └── a_generator.rb │ │ │ ├── default │ │ │ │ ├── empty │ │ │ │ │ └── .gitignore │ │ │ │ ├── plugin_with_no_lib_dir │ │ │ │ │ └── init.rb │ │ │ │ ├── acts │ │ │ │ │ └── acts_as_chunky_bacon │ │ │ │ │ │ └── lib │ │ │ │ │ │ └── .gitignore │ │ │ │ ├── gemlike │ │ │ │ │ ├── lib │ │ │ │ │ │ └── gemlike.rb │ │ │ │ │ └── init.rb │ │ │ │ └── stubby │ │ │ │ │ ├── about.yml │ │ │ │ │ ├── lib │ │ │ │ │ └── stubby_mixin.rb │ │ │ │ │ └── generators │ │ │ │ │ └── stubby_generator │ │ │ │ │ └── stubby_generator.rb │ │ │ └── engines │ │ │ │ └── engine │ │ │ │ ├── app │ │ │ │ ├── models │ │ │ │ │ └── engine_model.rb │ │ │ │ └── controllers │ │ │ │ │ └── engine_controller.rb │ │ │ │ ├── config │ │ │ │ ├── locales │ │ │ │ │ └── en.yml │ │ │ │ └── routes.rb │ │ │ │ └── init.rb │ │ ├── lib │ │ │ └── generators │ │ │ │ ├── missing_templates │ │ │ │ └── .gitignore │ │ │ │ ├── missing_class │ │ │ │ ├── templates │ │ │ │ │ └── .gitignore │ │ │ │ └── missing_class_generator.rb │ │ │ │ ├── missing_generator │ │ │ │ └── templates │ │ │ │ │ └── .gitignore │ │ │ │ └── working │ │ │ │ └── working_generator.rb │ │ ├── about_yml_plugins │ │ │ ├── bad_about_yml │ │ │ │ ├── init.rb │ │ │ │ └── about.yml │ │ │ └── plugin_without_about_yml │ │ │ │ └── init.rb │ │ ├── eager │ │ │ ├── zoo.rb │ │ │ └── zoo │ │ │ │ └── reptile_house.rb │ │ ├── environment_with_constant.rb │ │ └── metal │ │ │ ├── multiplemetals │ │ │ └── app │ │ │ │ └── metal │ │ │ │ ├── metal_a.rb │ │ │ │ └── metal_b.rb │ │ │ ├── singlemetal │ │ │ └── app │ │ │ │ └── metal │ │ │ │ └── foo_metal.rb │ │ │ ├── pluralmetal │ │ │ └── app │ │ │ │ └── metal │ │ │ │ └── legacy_routes.rb │ │ │ └── subfolders │ │ │ └── app │ │ │ └── metal │ │ │ └── Folder │ │ │ ├── metal_a.rb │ │ │ └── metal_b.rb │ ├── vendor │ │ └── gems │ │ │ ├── dummy-gem-i-1.0.0 │ │ │ ├── ext │ │ │ │ └── dummy-gem-i │ │ │ │ │ └── Makefile │ │ │ └── lib │ │ │ │ └── dummy-gem-i.rb │ │ │ ├── dummy-gem-a-0.4.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-a.rb │ │ │ ├── dummy-gem-b-0.4.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-b.rb │ │ │ ├── dummy-gem-b-0.6.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-b.rb │ │ │ ├── dummy-gem-c-0.4.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-c.rb │ │ │ ├── dummy-gem-c-0.6.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-c.rb │ │ │ ├── dummy-gem-d-1.0.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-d.rb │ │ │ ├── dummy-gem-e-1.0.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-e.rb │ │ │ ├── dummy-gem-f-1.0.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-f.rb │ │ │ ├── dummy-gem-g-1.0.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-g.rb │ │ │ ├── dummy-gem-h-1.0.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-h.rb │ │ │ ├── dummy-gem-j-1.0.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-j.rb │ │ │ ├── dummy-gem-k-1.0.0 │ │ │ └── lib │ │ │ │ └── dummy-gem-k.rb │ │ │ └── dummy-gem-l-1.0.0-x86-mswin32 │ │ │ └── lib │ │ │ └── dummy-gem-l.rb │ └── mocks │ │ └── routes.rb ├── lib │ ├── rails_generator │ │ ├── generators │ │ │ ├── components │ │ │ │ ├── mailer │ │ │ │ │ └── templates │ │ │ │ │ │ ├── view.rhtml │ │ │ │ │ │ ├── fixture.rhtml │ │ │ │ │ │ ├── fixture.erb │ │ │ │ │ │ └── view.erb │ │ │ │ ├── plugin │ │ │ │ │ └── templates │ │ │ │ │ │ ├── plugin.rb │ │ │ │ │ │ ├── init.rb │ │ │ │ │ │ ├── install.rb │ │ │ │ │ │ ├── uninstall.rb │ │ │ │ │ │ ├── tasks.rake │ │ │ │ │ │ ├── test_helper.rb │ │ │ │ │ │ ├── USAGE │ │ │ │ │ │ ├── unit_test.rb │ │ │ │ │ │ ├── generator.rb │ │ │ │ │ │ └── README │ │ │ │ ├── helper │ │ │ │ │ └── templates │ │ │ │ │ │ ├── helper.rb │ │ │ │ │ │ └── helper_test.rb │ │ │ │ ├── controller │ │ │ │ │ └── templates │ │ │ │ │ │ ├── helper.rb │ │ │ │ │ │ ├── view.html.erb │ │ │ │ │ │ ├── helper_test.rb │ │ │ │ │ │ ├── controller.rb │ │ │ │ │ │ └── functional_test.rb │ │ │ │ ├── resource │ │ │ │ │ └── templates │ │ │ │ │ │ ├── helper.rb │ │ │ │ │ │ ├── controller.rb │ │ │ │ │ │ ├── helper_test.rb │ │ │ │ │ │ └── functional_test.rb │ │ │ │ ├── scaffold │ │ │ │ │ └── templates │ │ │ │ │ │ ├── helper.rb │ │ │ │ │ │ └── helper_test.rb │ │ │ │ ├── observer │ │ │ │ │ └── templates │ │ │ │ │ │ ├── observer.rb │ │ │ │ │ │ └── unit_test.rb │ │ │ │ ├── metal │ │ │ │ │ ├── USAGE │ │ │ │ │ └── metal_generator.rb │ │ │ │ ├── model │ │ │ │ │ └── templates │ │ │ │ │ │ ├── model.rb │ │ │ │ │ │ └── unit_test.rb │ │ │ │ ├── integration_test │ │ │ │ │ └── templates │ │ │ │ │ │ └── integration_test.rb │ │ │ │ └── performance_test │ │ │ │ │ └── templates │ │ │ │ │ └── performance_test.rb │ │ │ └── applications │ │ │ │ └── app │ │ │ │ └── scm │ │ │ │ ├── svn.rb │ │ │ │ └── scm.rb │ │ └── scripts │ │ │ ├── generate.rb │ │ │ └── update.rb │ ├── railties_path.rb │ ├── commands │ │ ├── about.rb │ │ ├── update.rb │ │ ├── destroy.rb │ │ └── generate.rb │ ├── console_with_helpers.rb │ ├── rails │ │ ├── version.rb │ │ └── rack.rb │ ├── performance_test_help.rb │ ├── tasks │ │ ├── log.rake │ │ └── middleware.rake │ └── console_sandbox.rb ├── builtin │ └── rails_info │ │ ├── rails │ │ └── info_helper.rb │ │ └── rails_info_controller.rb ├── guides │ ├── images │ │ ├── fxn.jpg │ │ ├── csrf.png │ │ ├── habtm.png │ │ ├── bullet.gif │ │ ├── has_many.png │ │ ├── has_one.png │ │ ├── icons │ │ │ ├── up.png │ │ │ ├── home.png │ │ │ ├── next.png │ │ │ ├── note.png │ │ │ ├── prev.png │ │ │ ├── tip.png │ │ │ ├── caution.png │ │ │ ├── example.png │ │ │ ├── warning.png │ │ │ ├── important.png │ │ │ ├── callouts │ │ │ │ ├── 1.png │ │ │ │ ├── 10.png │ │ │ │ ├── 11.png │ │ │ │ ├── 12.png │ │ │ │ ├── 13.png │ │ │ │ ├── 14.png │ │ │ │ ├── 15.png │ │ │ │ ├── 2.png │ │ │ │ ├── 3.png │ │ │ │ ├── 4.png │ │ │ │ ├── 5.png │ │ │ │ ├── 6.png │ │ │ │ ├── 7.png │ │ │ │ ├── 8.png │ │ │ │ └── 9.png │ │ │ └── README │ │ ├── tab_grey.gif │ │ ├── tab_info.gif │ │ ├── tab_note.gif │ │ ├── tab_red.gif │ │ ├── belongs_to.png │ │ ├── book_icon.gif │ │ ├── nav_arrow.gif │ │ ├── tab_yellow.gif │ │ ├── tab_yellow.png │ │ ├── chapters_icon.gif │ │ ├── check_bullet.gif │ │ ├── feature_tile.gif │ │ ├── footer_tile.gif │ │ ├── grey_bullet.gif │ │ ├── header_tile.gif │ │ ├── polymorphic.png │ │ ├── posts_index.png │ │ ├── rails_welcome.png │ │ ├── error_messages.png │ │ ├── has_one_through.png │ │ ├── header_backdrop.png │ │ ├── credits_pic_blank.gif │ │ ├── has_many_through.png │ │ ├── rails_guides_logo.gif │ │ ├── rails_logo_remix.gif │ │ ├── session_fixation.png │ │ ├── i18n │ │ │ ├── demo_translated_en.png │ │ │ ├── demo_untranslated.png │ │ │ ├── demo_localized_pirate.png │ │ │ ├── demo_translated_pirate.png │ │ │ └── demo_translation_missing.png │ │ ├── customized_error_messages.png │ │ └── validation_error_messages.png │ └── files │ │ └── javascripts │ │ └── guides.js ├── bin │ ├── console │ ├── destroy │ ├── generate │ ├── plugin │ ├── runner │ ├── server │ ├── dbconsole │ ├── performance │ │ ├── profiler │ │ └── benchmarker │ └── about ├── helpers │ ├── application_helper.rb │ └── performance_test.rb ├── dispatches │ └── config.ru └── doc │ └── README_FOR_APP ├── activerecord ├── test │ ├── fixtures │ │ ├── all │ │ │ ├── people.csv │ │ │ ├── tasks.yml │ │ │ └── developers.yml │ │ ├── .gitignore │ │ ├── naked │ │ │ ├── csv │ │ │ │ └── accounts.csv │ │ │ └── yml │ │ │ │ ├── accounts.yml │ │ │ │ ├── courses.yml │ │ │ │ └── companies.yml │ │ ├── fk_test_has_pk.yml │ │ ├── minimalistics.yml │ │ ├── fk_test_has_fk.yml │ │ ├── items.yml │ │ ├── warehouse-things.yml │ │ ├── tees.yml │ │ ├── ties.yml │ │ ├── legacy_things.yml │ │ ├── toys.yml │ │ ├── men.yml │ │ ├── reserved_words │ │ │ ├── distinct.yml │ │ │ ├── select.yml │ │ │ ├── values.yml │ │ │ ├── group.yml │ │ │ └── distincts_selects.yml │ │ ├── author_favorites.yml │ │ ├── computers.yml │ │ ├── author_addresses.yml │ │ ├── tags.yml │ │ ├── vertices.yml │ │ ├── organizations.yml │ │ ├── ships.yml │ │ ├── zines.yml │ │ ├── jobs.yml │ │ ├── member_types.yml │ │ ├── courses.yml │ │ ├── mixed_case_monkeys.yml │ │ ├── movies.yml │ │ ├── owners.yml │ │ ├── books.yml │ │ ├── projects.yml │ │ ├── edges.yml │ │ ├── members.yml │ │ ├── subscribers.yml │ │ ├── readers.yml │ │ ├── authors.yml │ │ ├── mateys.yml │ │ ├── price_estimates.yml │ │ ├── categories │ │ │ ├── subsubdir │ │ │ │ └── arbitrary_filename.yml │ │ │ └── special_categories.yml │ │ ├── clubs.yml │ │ ├── funny_jokes.yml │ │ ├── treasures.yml │ │ ├── credential_usages.yml │ │ ├── categories_ordered_primary_tag_handle.yml │ │ ├── categories_ordered_secondary_tag_handle.yml │ │ ├── pets.yml │ │ ├── entrants.yml │ │ ├── tasks.yml │ │ ├── faces.yml │ │ ├── pirates.yml │ │ ├── categories.yml │ │ ├── subscriptions.yml │ │ ├── credentials.yml │ │ ├── parrots_pirates.yml │ │ ├── people.yml │ │ └── references.yml │ ├── models │ │ ├── guid.rb │ │ ├── binary.rb │ │ ├── default.rb │ │ ├── task.rb │ │ ├── minimalistic.rb │ │ ├── course.rb │ │ ├── entrant.rb │ │ ├── event.rb │ │ ├── joke.rb │ │ ├── member_type.rb │ │ ├── keyboard.rb │ │ ├── credential_usage.rb │ │ ├── legacy_thing.rb │ │ ├── line_item.rb │ │ ├── reader.rb │ │ ├── zine.rb │ │ ├── column_name.rb │ │ ├── mixed_case_monkey.rb │ │ ├── movie.rb │ │ ├── reference.rb │ │ ├── computer.rb │ │ ├── contract.rb │ │ ├── essay.rb │ │ ├── polymorphic_price.rb │ │ ├── price_estimate.rb │ │ ├── subscription.rb │ │ ├── matey.rb │ │ ├── polymorphic_design.rb │ │ ├── subject.rb │ │ ├── categorization.rb │ │ ├── credential.rb │ │ ├── pet.rb │ │ ├── owner.rb │ │ ├── auto_id.rb │ │ ├── tee.rb │ │ ├── tie.rb │ │ ├── warehouse_thing.rb │ │ ├── member_detail.rb │ │ ├── item.rb │ │ ├── event_author.rb │ │ ├── invoice.rb │ │ ├── job.rb │ │ ├── sponsor.rb │ │ ├── toy.rb │ │ ├── book.rb │ │ ├── organization.rb │ │ ├── membership.rb │ │ ├── subscriber.rb │ │ ├── order.rb │ │ ├── tag.rb │ │ ├── interest.rb │ │ ├── treasure.rb │ │ ├── ship_part.rb │ │ ├── edge.rb │ │ ├── bird.rb │ │ ├── citation.rb │ │ └── topic_kwarg_scopes.rb │ ├── assets │ │ ├── example.log │ │ └── flowers.jpg │ ├── migrations │ │ ├── duplicate │ │ │ ├── 3_foo.rb │ │ │ ├── 1_people_have_last_names.rb │ │ │ └── 2_we_need_reminders.rb │ │ ├── duplicate_names │ │ │ ├── 20080507052938_chunky.rb │ │ │ └── 20080507053028_chunky.rb │ │ ├── interleaved │ │ │ ├── pass_3 │ │ │ │ ├── 2_i_raise_on_down.rb │ │ │ │ └── 1_people_have_last_names.rb │ │ │ └── pass_2 │ │ │ │ └── 1_people_have_last_names.rb │ │ ├── valid │ │ │ ├── 1_people_have_last_names.rb │ │ │ └── 2_we_need_reminders.rb │ │ ├── missing │ │ │ ├── 1_people_have_last_names.rb │ │ │ ├── 1000_people_have_middle_names.rb │ │ │ └── 3_we_need_reminders.rb │ │ └── broken │ │ │ └── 100_migration_that_raises_exception.rb │ ├── schema │ │ └── schema2.rb │ ├── config.rb │ └── cases │ │ └── connection_test_firebird.rb ├── examples │ ├── .gitignore │ └── associations.png └── lib │ ├── activerecord.rb │ └── active_record │ └── version.rb ├── actionpack ├── test │ ├── fixtures │ │ ├── shared.html.erb │ │ ├── test │ │ │ ├── _two.html.erb │ │ │ ├── _hello.builder │ │ │ ├── _partial.erb │ │ │ ├── _partial.js.erb │ │ │ ├── hello_world.erb │ │ │ ├── _partial.html.erb │ │ │ ├── _partial_only.erb │ │ │ ├── dont_pick_me │ │ │ ├── hello_world.da.html.erb │ │ │ ├── hello_world.erb~ │ │ │ ├── hyphen-ated.erb │ │ │ ├── template.erb │ │ │ ├── _form.erb │ │ │ ├── _raise.html.erb │ │ │ ├── greeting.erb │ │ │ ├── hello_world.pt-BR.html.erb │ │ │ ├── translation.erb │ │ │ ├── _counter.html.erb │ │ │ ├── _from_helper.erb │ │ │ ├── _utf8_partial.html.erb │ │ │ ├── formatted_xml_erb.builder │ │ │ ├── malformed │ │ │ │ ├── malformed.erb~ │ │ │ │ ├── malformed.en.html.erb~ │ │ │ │ └── malformed.html.erb~ │ │ │ ├── formatted_html_erb.html.erb │ │ │ ├── hello_world_with_layout_false.erb │ │ │ ├── greeting.js.rjs │ │ │ ├── greeting.registered.erb │ │ │ ├── greeting.unregistered.erb │ │ │ ├── _labelling_form.erb │ │ │ ├── _one.html.erb │ │ │ ├── implicit_content_type.atom.builder │ │ │ ├── inspect_local_assigns.erb │ │ │ ├── render_file_with_ivar.erb │ │ │ ├── _customer.erb │ │ │ ├── _person.erb │ │ │ ├── formatted_xml_erb.xml.erb │ │ │ ├── render_file_from_template.html.erb │ │ │ ├── render_file_with_locals.erb │ │ │ ├── _customer_counter_with_as.erb │ │ │ ├── _customer_greeting.erb │ │ │ ├── _hash_greeting.erb │ │ │ ├── _partial_for_use_in_layout.html.erb │ │ │ ├── formatted_xml_erb.html.erb │ │ │ ├── render_implicit_html_template_from_xhr_request.html.erb │ │ │ ├── render_to_string_test.erb │ │ │ ├── scoped_array_translation.erb │ │ │ ├── sub_template_raise.html.erb │ │ │ ├── _partial_with_only_html_version.html.erb │ │ │ ├── dot.directory │ │ │ │ └── render_file_with_ivar.erb │ │ │ ├── render_implicit_html_template_from_xhr_request.da.html.erb │ │ │ ├── render_implicit_js_template_without_layout.js.erb │ │ │ ├── _layout_for_partial.html.erb │ │ │ ├── _local_inspector.html.erb │ │ │ ├── _utf8_partial_magic.html.erb │ │ │ ├── _customer_counter.erb │ │ │ ├── _layout_for_block_with_args.html.erb │ │ │ ├── action_talk_to_layout.erb │ │ │ ├── _customer_with_var.erb │ │ │ ├── _hash_object.erb │ │ │ ├── capturing.erb │ │ │ ├── content_for.erb │ │ │ ├── render_implicit_html_template.js.rjs │ │ │ ├── content_for_with_parameter.erb │ │ │ ├── delete_with_js.rjs │ │ │ ├── hello_world_from_rxml.builder │ │ │ ├── render_explicit_html_template.js.rjs │ │ │ ├── hello.builder │ │ │ ├── hello_world_container.builder │ │ │ ├── content_for_concatenated.erb │ │ │ ├── list.erb │ │ │ ├── non_erb_block_content_for.builder │ │ │ ├── using_layout_around_block_with_args.html.erb │ │ │ ├── using_layout_around_block.html.erb │ │ │ ├── calling_partial_with_layout.html.erb │ │ │ ├── utf8.html.erb │ │ │ ├── nested_layout.erb │ │ │ ├── potential_conflicts.erb │ │ │ ├── array_translation.erb │ │ │ ├── utf8_magic.html.erb │ │ │ ├── utf8_magic_with_bare_partial.html.erb │ │ │ ├── hello_xml_world.builder │ │ │ └── enum_rjs_test.rjs │ │ ├── multipart │ │ │ ├── hello.txt │ │ │ ├── bracketed_param │ │ │ ├── single_parameter │ │ │ ├── binary_file │ │ │ ├── mixed_files │ │ │ ├── mona_lisa.jpg │ │ │ ├── none │ │ │ ├── empty │ │ │ └── text_file │ │ ├── fun │ │ │ ├── games │ │ │ │ ├── _game.erb │ │ │ │ └── hello_world.erb │ │ │ └── serious │ │ │ │ └── games │ │ │ │ └── _game.erb │ │ ├── layout_tests │ │ │ ├── alt │ │ │ │ ├── layouts │ │ │ │ │ └── alt.rhtml │ │ │ │ └── hello.rhtml │ │ │ ├── views │ │ │ │ └── hello.rhtml │ │ │ ├── layouts │ │ │ │ ├── symlinked │ │ │ │ ├── item.rhtml │ │ │ │ ├── third_party_template_library.mab │ │ │ │ ├── layout_test.rhtml │ │ │ │ ├── multiple_extensions.html.erb │ │ │ │ └── controller_name_space │ │ │ │ │ └── nested.rhtml │ │ │ └── abs_path_layout.rhtml │ │ ├── public │ │ │ ├── 404.html │ │ │ ├── 500.html │ │ │ ├── javascripts │ │ │ │ ├── bank.js │ │ │ │ ├── effects.js │ │ │ │ ├── robber.js │ │ │ │ ├── controls.js │ │ │ │ ├── dragdrop.js │ │ │ │ ├── prototype.js │ │ │ │ ├── application.js │ │ │ │ ├── subdir │ │ │ │ │ └── subdir.js │ │ │ │ └── version.1.0.js │ │ │ ├── stylesheets │ │ │ │ ├── bank.css │ │ │ │ ├── robber.css │ │ │ │ ├── subdir │ │ │ │ │ └── subdir.css │ │ │ │ └── version.1.0.css │ │ │ ├── 500.da.html │ │ │ └── images │ │ │ │ └── rails.png │ │ ├── replies │ │ │ └── _reply.erb │ │ ├── failsafe │ │ │ └── 500.html │ │ ├── layouts │ │ │ ├── xhr.html.erb │ │ │ ├── default_html.html.erb │ │ │ ├── yield.erb │ │ │ ├── builder.builder │ │ │ ├── standard.erb │ │ │ ├── _column.html.erb │ │ │ ├── talk_from_action.erb │ │ │ ├── partial_with_layout.erb │ │ │ └── block_with_layout.erb │ │ ├── localized │ │ │ ├── hello_world.de.html │ │ │ └── hello_world.en.html │ │ ├── mascots │ │ │ └── _mascot.html.erb │ │ ├── post_test │ │ │ ├── post │ │ │ │ ├── index.html.erb │ │ │ │ └── index.iphone.erb │ │ │ ├── super_post │ │ │ │ ├── index.html.erb │ │ │ │ └── index.iphone.erb │ │ │ └── layouts │ │ │ │ ├── post.html.erb │ │ │ │ └── super_post.iphone.erb │ │ ├── projects │ │ │ └── _project.erb │ │ ├── topics │ │ │ └── _topic.html.erb │ │ ├── _top_level_partial_only.erb │ │ ├── developers │ │ │ └── _developer.erb │ │ ├── respond_to │ │ │ ├── using_defaults.html.erb │ │ │ ├── using_defaults.xml.builder │ │ │ ├── using_defaults_with_type_list.html.erb │ │ │ ├── custom_constant_handling_without_block.mobile.erb │ │ │ ├── using_defaults.js.rjs │ │ │ ├── all_types_with_layout.html.erb │ │ │ ├── any_template.unregistered.erb │ │ │ ├── using_defaults_with_type_list.xml.builder │ │ │ ├── all_types_with_layout.js.rjs │ │ │ ├── iphone_with_html_response_type.html.erb │ │ │ ├── layouts │ │ │ │ ├── standard.html.erb │ │ │ │ ├── standard.iphone.erb │ │ │ │ └── missing.html.erb │ │ │ ├── using_defaults_with_type_list.js.rjs │ │ │ ├── iphone_with_html_response_type.iphone.erb │ │ │ └── any_template.registered.erb │ │ ├── scope │ │ │ └── test │ │ │ │ └── modgreet.erb │ │ ├── _top_level_partial.html.erb │ │ ├── addresses │ │ │ └── list.erb │ │ ├── override │ │ │ └── test │ │ │ │ └── hello_world.erb │ │ ├── override2 │ │ │ └── layouts │ │ │ │ └── test │ │ │ │ └── sub.erb │ │ ├── quiz │ │ │ └── questions │ │ │ │ └── _question.html.erb │ │ ├── content_type │ │ │ ├── render_default_for_rxml.rxml │ │ │ ├── render_default_for_rhtml.rhtml │ │ │ ├── render_default_for_rjs.rjs │ │ │ └── render_default_content_types_for_respond_to.rhtml │ │ ├── customers │ │ │ └── _customer.html.erb │ │ ├── mascot.rb │ │ ├── alternate_helpers │ │ │ └── foo_helper.rb │ │ ├── mascots.yml │ │ ├── helpers │ │ │ ├── fun │ │ │ │ ├── pdf_helper.rb │ │ │ │ └── games_helper.rb │ │ │ └── abc_helper.rb │ │ ├── functional_caching │ │ │ ├── _partial.erb │ │ │ ├── html_fragment_cached_with_partial.html.erb │ │ │ ├── fragment_cached.html.erb │ │ │ ├── js_fragment_cached_with_partial.js.rjs │ │ │ ├── formatted_fragment_cached.html.erb │ │ │ ├── formatted_fragment_cached.xml.builder │ │ │ ├── inline_fragment_cached.html.erb │ │ │ └── formatted_fragment_cached.js.rjs │ │ ├── symlink_parent │ │ │ └── symlinked_layout.erb │ │ ├── topic.rb │ │ ├── bad_customers │ │ │ └── _bad_customer.html.erb │ │ ├── project.rb │ │ ├── good_customers │ │ │ └── _good_customer.html.erb │ │ ├── projects.yml │ │ ├── reply.rb │ │ ├── developer.rb │ │ ├── session_autoload_test │ │ │ └── session_autoload_test │ │ │ │ └── foo.rb │ │ ├── company.rb │ │ └── developers_projects.yml │ └── controller │ │ └── controller_fixtures │ │ ├── app │ │ └── controllers │ │ │ ├── user_controller.rb │ │ │ └── admin │ │ │ └── user_controller.rb │ │ └── vendor │ │ └── plugins │ │ └── bad_plugin │ │ └── lib │ │ └── plugin_controller.rb └── lib │ ├── action_controller │ ├── templates │ │ └── rescues │ │ │ ├── unknown_action.erb │ │ │ └── missing_template.erb │ ├── vendor │ │ └── html-scanner │ │ │ └── html │ │ │ └── version.rb │ └── translation.rb │ ├── actionpack.rb │ ├── action_pack │ └── version.rb │ └── action_view │ └── helpers │ └── raw_output_helper.rb ├── activesupport ├── test │ ├── dependencies │ │ ├── conflict.rb │ │ ├── service_two.rb │ │ ├── requires_nonexistent0.rb │ │ ├── requires_nonexistent1.rb │ │ ├── cross_site_depender.rb │ │ ├── check_warnings.rb │ │ ├── service_one.rb │ │ ├── mutual_one.rb │ │ ├── mutual_two.rb │ │ └── raises_exception.rb │ ├── autoloading_fixtures │ │ ├── conflict.rb │ │ ├── e.rb │ │ ├── a │ │ │ ├── b.rb │ │ │ └── c │ │ │ │ ├── d.rb │ │ │ │ └── e │ │ │ │ └── f.rb │ │ ├── application.rb │ │ ├── cross_site_dependency.rb │ │ ├── class_folder │ │ │ ├── inline_class.rb │ │ │ ├── class_folder_subclass.rb │ │ │ └── nested_class.rb │ │ ├── module_folder │ │ │ ├── inline_class.rb │ │ │ ├── nested_sibling.rb │ │ │ └── nested_class.rb │ │ ├── raises_name_error.rb │ │ ├── module_with_custom_const_missing │ │ │ └── a │ │ │ │ └── b.rb │ │ ├── class_folder.rb │ │ ├── multiple_constant_file.rb │ │ ├── raises_no_method_error.rb │ │ └── counting_loader.rb │ ├── empty_bool.rb │ ├── core_ext │ │ └── object_ext_test.rb │ └── gzip_test.rb └── lib │ ├── active_support │ ├── core_ext │ │ ├── process.rb │ │ ├── string │ │ │ └── bytesize.rb │ │ ├── file.rb │ │ ├── module │ │ │ └── remove_method.rb │ │ ├── cgi.rb │ │ ├── base64.rb │ │ ├── pathname.rb │ │ ├── kernel │ │ │ └── daemonizing.rb │ │ ├── blank.rb │ │ ├── float.rb │ │ ├── kernel.rb │ │ └── class.rb │ ├── vendor │ │ ├── i18n-0.4.1 │ │ │ └── i18n │ │ │ │ ├── version.rb │ │ │ │ └── locale.rb │ │ └── tzinfo-0.3.53 │ │ │ └── tzinfo │ │ │ └── definitions │ │ │ ├── GMT.rb │ │ │ ├── UCT.rb │ │ │ ├── UTC.rb │ │ │ ├── GB.rb │ │ │ ├── GMT0.rb │ │ │ ├── Iran.rb │ │ │ ├── NZ.rb │ │ │ ├── PRC.rb │ │ │ ├── ROC.rb │ │ │ ├── ROK.rb │ │ │ ├── Zulu.rb │ │ │ ├── Cuba.rb │ │ │ ├── Egypt.rb │ │ │ ├── Eire.rb │ │ │ ├── Japan.rb │ │ │ ├── GMT__m__0.rb │ │ │ ├── GMT__p__0.rb │ │ │ ├── Israel.rb │ │ │ ├── Libya.rb │ │ │ ├── Navajo.rb │ │ │ ├── Poland.rb │ │ │ ├── Turkey.rb │ │ │ ├── W__m__SU.rb │ │ │ ├── Greenwich.rb │ │ │ ├── Hongkong.rb │ │ │ ├── Jamaica.rb │ │ │ ├── Portugal.rb │ │ │ ├── Universal.rb │ │ │ ├── GB__m__Eire.rb │ │ │ ├── Iceland.rb │ │ │ ├── Singapore.rb │ │ │ ├── Kwajalein.rb │ │ │ └── NZ__m__CHAT.rb │ ├── json.rb │ ├── json │ │ ├── encoders │ │ │ ├── symbol.rb │ │ │ ├── nil_class.rb │ │ │ ├── true_class.rb │ │ │ ├── false_class.rb │ │ │ ├── regexp.rb │ │ │ ├── string.rb │ │ │ └── object.rb │ │ └── variable.rb │ ├── values │ │ └── unicode_tables.dat │ ├── version.rb │ ├── multibyte │ │ └── exceptions.rb │ ├── testing │ │ └── default.rb │ ├── core_ext.rb │ └── all.rb │ └── activesupport.rb ├── actionmailer ├── test │ └── fixtures │ │ ├── auto_layout_mailer │ │ ├── hello.html.erb │ │ ├── multipart.text.html.erb │ │ └── multipart.text.plain.erb │ │ ├── first_mailer │ │ └── share.erb │ │ ├── second_mailer │ │ └── share.erb │ │ ├── layouts │ │ ├── spam.html.erb │ │ ├── auto_layout_mailer.html.erb │ │ └── auto_layout_mailer.text.erb │ │ ├── test_mailer │ │ ├── _subtemplate.text.plain.erb │ │ ├── rxml_template.rxml │ │ ├── rxml_template.builder │ │ ├── body_ivar.erb │ │ ├── signed_up.html.erb │ │ ├── implicitly_multipart_example.text.yaml.erb │ │ ├── included_subtemplate.text.plain.erb │ │ ├── implicitly_multipart_example.ignored.erb │ │ ├── implicitly_multipart_example.rhtml.bak │ │ ├── custom_templating_extension.text.html.haml │ │ ├── custom_templating_extension.text.plain.haml │ │ ├── implicitly_multipart_example.text.plain.erb │ │ ├── signed_up_with_url.erb │ │ ├── implicitly_multipart_example.text.html.erb │ │ └── implicitly_multipart_example.text.html.erb~ │ │ ├── explicit_layout_mailer │ │ ├── logout.html.erb │ │ └── signup.html.erb │ │ ├── templates │ │ └── signed_up.erb │ │ ├── asset_host_mailer │ │ └── email_with_asset.html.erb │ │ ├── helper_mailer │ │ ├── use_example_helper.erb │ │ ├── use_helper.erb │ │ ├── use_helper_method.erb │ │ └── use_mail_helper.erb │ │ ├── path.with.dots │ │ └── funky_path_mailer │ │ │ └── multipart_with_template_path_with_dots.erb │ │ └── helpers │ │ └── example_helper.rb └── lib │ ├── action_mailer │ ├── vendor │ │ ├── tmail-1.2.7 │ │ │ ├── tmail │ │ │ │ ├── .cvsignore │ │ │ │ ├── mbox.rb │ │ │ │ ├── loader.rb │ │ │ │ ├── main.rb │ │ │ │ └── index.rb │ │ │ └── tmail.rb │ │ └── text_format.rb │ ├── utils.rb │ └── version.rb │ └── actionmailer.rb ├── activeresource ├── test │ └── fixtures │ │ ├── person.rb │ │ ├── customer.rb │ │ ├── proxy.rb │ │ └── street_address.rb └── lib │ ├── activeresource.rb │ └── active_resource │ └── version.rb ├── activemodel ├── lib │ ├── active_model │ │ ├── callbacks.rb │ │ └── base.rb │ └── active_model.rb └── Rakefile ├── Gemfile ├── Gemfile.lock └── .gitignore /rack/test/.bacon: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.ruby-version: -------------------------------------------------------------------------------- 1 | 3.1 2 | -------------------------------------------------------------------------------- /Gemfile.1.8: -------------------------------------------------------------------------------- 1 | Gemfile.common -------------------------------------------------------------------------------- /Gemfile.2.3: -------------------------------------------------------------------------------- 1 | Gemfile.common -------------------------------------------------------------------------------- /Gemfile.2.5: -------------------------------------------------------------------------------- 1 | Gemfile.common -------------------------------------------------------------------------------- /Gemfile.2.7: -------------------------------------------------------------------------------- 1 | Gemfile.common -------------------------------------------------------------------------------- /Gemfile.3.1: -------------------------------------------------------------------------------- 1 | Gemfile.common -------------------------------------------------------------------------------- /Gemfile.3.3: -------------------------------------------------------------------------------- 1 | Gemfile.common -------------------------------------------------------------------------------- /railties/configs/empty.log: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /railties/html/favicon.ico: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /rack/test/multipart/file1.txt: -------------------------------------------------------------------------------- 1 | contents -------------------------------------------------------------------------------- /rack/test/static/index.html: -------------------------------------------------------------------------------- 1 | index! 2 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/all/people.csv: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/all/tasks.yml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /rack/test/rackup/.gitignore: -------------------------------------------------------------------------------- 1 | log_output 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/shared.html.erb: -------------------------------------------------------------------------------- 1 | Elastica -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_two.html.erb: -------------------------------------------------------------------------------- 1 | Hello -------------------------------------------------------------------------------- /activerecord/test/fixtures/.gitignore: -------------------------------------------------------------------------------- 1 | *.sqlite* -------------------------------------------------------------------------------- /activerecord/test/fixtures/all/developers.yml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/multipart/hello.txt: -------------------------------------------------------------------------------- 1 | Hello -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_hello.builder: -------------------------------------------------------------------------------- 1 | xm.hello -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_partial.erb: -------------------------------------------------------------------------------- 1 | invalid -------------------------------------------------------------------------------- /activerecord/examples/.gitignore: -------------------------------------------------------------------------------- 1 | performance.sql 2 | -------------------------------------------------------------------------------- /rack/test/cgi/assets/index.html: -------------------------------------------------------------------------------- 1 | ### TestFile ### 2 | -------------------------------------------------------------------------------- /railties/test/fixtures/public/index.html: -------------------------------------------------------------------------------- 1 | /index.html -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_partial.js.erb: -------------------------------------------------------------------------------- 1 | partial js -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/hello_world.erb: -------------------------------------------------------------------------------- 1 | Hello world! -------------------------------------------------------------------------------- /activerecord/test/fixtures/naked/csv/accounts.csv: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/naked/yml/accounts.yml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /activesupport/test/dependencies/conflict.rb: -------------------------------------------------------------------------------- 1 | Conflict = 1 -------------------------------------------------------------------------------- /rack/test/cgi/assets/folder/test.js: -------------------------------------------------------------------------------- 1 | ### TestFile ### 2 | -------------------------------------------------------------------------------- /rack/test/cgi/assets/fonts/font.eot: -------------------------------------------------------------------------------- 1 | ### TestFile ### 2 | -------------------------------------------------------------------------------- /rack/test/cgi/assets/images/image.png: -------------------------------------------------------------------------------- 1 | ### TestFile ### 2 | -------------------------------------------------------------------------------- /rack/test/static/another/index.html: -------------------------------------------------------------------------------- 1 | another index! 2 | -------------------------------------------------------------------------------- /railties/test/fixtures/plugins/alternate/a/lib/.gitignore: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /railties/test/fixtures/plugins/default/empty/.gitignore: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /railties/test/fixtures/public/foo/bar.html: -------------------------------------------------------------------------------- 1 | /foo/bar.html -------------------------------------------------------------------------------- /actionpack/test/fixtures/fun/games/_game.erb: -------------------------------------------------------------------------------- 1 | <%= game.name %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/layout_tests/alt/layouts/alt.rhtml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/404.html: -------------------------------------------------------------------------------- 1 | 404 error fixture 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/500.html: -------------------------------------------------------------------------------- 1 | 500 error fixture 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/javascripts/bank.js: -------------------------------------------------------------------------------- 1 | // bank js -------------------------------------------------------------------------------- /actionpack/test/fixtures/replies/_reply.erb: -------------------------------------------------------------------------------- 1 | <%= reply.content %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_partial.html.erb: -------------------------------------------------------------------------------- 1 | partial html -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_partial_only.erb: -------------------------------------------------------------------------------- 1 | only partial -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/dont_pick_me: -------------------------------------------------------------------------------- 1 | non-template file -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/hello_world.da.html.erb: -------------------------------------------------------------------------------- 1 | Hey verden -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/hello_world.erb~: -------------------------------------------------------------------------------- 1 | Don't pick me! -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/hyphen-ated.erb: -------------------------------------------------------------------------------- 1 | Hello world! 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/template.erb: -------------------------------------------------------------------------------- 1 | <%= template.path %> -------------------------------------------------------------------------------- /activerecord/test/fixtures/fk_test_has_pk.yml: -------------------------------------------------------------------------------- 1 | first: 2 | id: 1 -------------------------------------------------------------------------------- /activerecord/test/fixtures/naked/yml/courses.yml: -------------------------------------------------------------------------------- 1 | qwerty 2 | -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/conflict.rb: -------------------------------------------------------------------------------- 1 | Conflict = 2 -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/e.rb: -------------------------------------------------------------------------------- 1 | class E 2 | end -------------------------------------------------------------------------------- /rack/test/cgi/assets/javascripts/app.js: -------------------------------------------------------------------------------- 1 | ### TestFile ### 2 | -------------------------------------------------------------------------------- /rack/test/cgi/assets/stylesheets/app.css: -------------------------------------------------------------------------------- 1 | ### TestFile ### 2 | -------------------------------------------------------------------------------- /railties/test/fixtures/public/foo/index.html: -------------------------------------------------------------------------------- 1 | /foo/index.html -------------------------------------------------------------------------------- /actionmailer/test/fixtures/auto_layout_mailer/hello.html.erb: -------------------------------------------------------------------------------- 1 | Inside -------------------------------------------------------------------------------- /actionmailer/test/fixtures/first_mailer/share.erb: -------------------------------------------------------------------------------- 1 | first mail 2 | -------------------------------------------------------------------------------- /actionmailer/test/fixtures/second_mailer/share.erb: -------------------------------------------------------------------------------- 1 | second mail 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/failsafe/500.html: -------------------------------------------------------------------------------- 1 | hello <%= "my" %> world -------------------------------------------------------------------------------- /actionpack/test/fixtures/fun/serious/games/_game.erb: -------------------------------------------------------------------------------- 1 | <%= game.name %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/layout_tests/views/hello.rhtml: -------------------------------------------------------------------------------- 1 | hello.rhtml -------------------------------------------------------------------------------- /actionpack/test/fixtures/layouts/xhr.html.erb: -------------------------------------------------------------------------------- 1 | XHR! 2 | <%= yield %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/localized/hello_world.de.html: -------------------------------------------------------------------------------- 1 | Gutten Tag -------------------------------------------------------------------------------- /actionpack/test/fixtures/localized/hello_world.en.html: -------------------------------------------------------------------------------- 1 | Hello World -------------------------------------------------------------------------------- /actionpack/test/fixtures/mascots/_mascot.html.erb: -------------------------------------------------------------------------------- 1 | <%= mascot.name %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/post_test/post/index.html.erb: -------------------------------------------------------------------------------- 1 | Hello Firefox -------------------------------------------------------------------------------- /actionpack/test/fixtures/post_test/post/index.iphone.erb: -------------------------------------------------------------------------------- 1 | Hello iPhone -------------------------------------------------------------------------------- /actionpack/test/fixtures/projects/_project.erb: -------------------------------------------------------------------------------- 1 | <%= project.name %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/javascripts/effects.js: -------------------------------------------------------------------------------- 1 | // effects js -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/javascripts/robber.js: -------------------------------------------------------------------------------- 1 | // robber js -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/stylesheets/bank.css: -------------------------------------------------------------------------------- 1 | /* bank.css */ -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_form.erb: -------------------------------------------------------------------------------- 1 | <%= form.label :title %> 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_raise.html.erb: -------------------------------------------------------------------------------- 1 | <%= doesnt_exist %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/greeting.erb: -------------------------------------------------------------------------------- 1 |
This is grand!
2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/hello_world.pt-BR.html.erb: -------------------------------------------------------------------------------- 1 | Ola mundo -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/translation.erb: -------------------------------------------------------------------------------- 1 | <%= t('.helper') %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/topics/_topic.html.erb: -------------------------------------------------------------------------------- 1 | <%= topic.title %> -------------------------------------------------------------------------------- /activerecord/test/fixtures/minimalistics.yml: -------------------------------------------------------------------------------- 1 | first: 2 | id: 1 3 | -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/a/b.rb: -------------------------------------------------------------------------------- 1 | class A::B 2 | end -------------------------------------------------------------------------------- /rack/test/cgi/test+directory/test+file: -------------------------------------------------------------------------------- 1 | this file has plusses! 2 | -------------------------------------------------------------------------------- /railties/test/fixtures/lib/generators/missing_templates/.gitignore: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /railties/test/vendor/gems/dummy-gem-i-1.0.0/ext/dummy-gem-i/Makefile: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/_top_level_partial_only.erb: -------------------------------------------------------------------------------- 1 | top level partial -------------------------------------------------------------------------------- /actionpack/test/fixtures/developers/_developer.erb: -------------------------------------------------------------------------------- 1 | <%= developer.name %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/layout_tests/alt/hello.rhtml: -------------------------------------------------------------------------------- 1 | alt/hello.rhtml 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/post_test/super_post/index.html.erb: -------------------------------------------------------------------------------- 1 | Super Firefox -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/javascripts/controls.js: -------------------------------------------------------------------------------- 1 | // controls js -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/javascripts/dragdrop.js: -------------------------------------------------------------------------------- 1 | // dragdrop js -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/javascripts/prototype.js: -------------------------------------------------------------------------------- 1 | // prototype js -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/stylesheets/robber.css: -------------------------------------------------------------------------------- 1 | /* robber.css */ -------------------------------------------------------------------------------- /actionpack/test/fixtures/respond_to/using_defaults.html.erb: -------------------------------------------------------------------------------- 1 | Hello world! -------------------------------------------------------------------------------- /actionpack/test/fixtures/scope/test/modgreet.erb: -------------------------------------------------------------------------------- 1 |Beautiful modules!
-------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_counter.html.erb: -------------------------------------------------------------------------------- 1 | <%= counter_counter %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_from_helper.erb: -------------------------------------------------------------------------------- 1 | <%= render_from_helper %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_utf8_partial.html.erb: -------------------------------------------------------------------------------- 1 | <%= "текст" %> 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/formatted_xml_erb.builder: -------------------------------------------------------------------------------- 1 | xml.test 'failed' -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/malformed/malformed.erb~: -------------------------------------------------------------------------------- 1 | Don't render me! -------------------------------------------------------------------------------- /activerecord/test/models/guid.rb: -------------------------------------------------------------------------------- 1 | class Guid < ActiveRecord::Base 2 | end -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/a/c/d.rb: -------------------------------------------------------------------------------- 1 | class A::C::D 2 | end -------------------------------------------------------------------------------- /activesupport/test/dependencies/service_two.rb: -------------------------------------------------------------------------------- 1 | class ServiceTwo 2 | end -------------------------------------------------------------------------------- /railties/test/fixtures/lib/generators/missing_class/templates/.gitignore: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /railties/test/fixtures/plugins/default/plugin_with_no_lib_dir/init.rb: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /actionmailer/test/fixtures/layouts/spam.html.erb: -------------------------------------------------------------------------------- 1 | Spammer layout <%= yield %> -------------------------------------------------------------------------------- /actionmailer/test/fixtures/test_mailer/_subtemplate.text.plain.erb: -------------------------------------------------------------------------------- 1 | let's go! -------------------------------------------------------------------------------- /actionpack/test/fixtures/_top_level_partial.html.erb: -------------------------------------------------------------------------------- 1 | top level partial html -------------------------------------------------------------------------------- /actionpack/test/fixtures/addresses/list.erb: -------------------------------------------------------------------------------- 1 | We only need to get this far! 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/fun/games/hello_world.erb: -------------------------------------------------------------------------------- 1 | Living in a nested world -------------------------------------------------------------------------------- /actionpack/test/fixtures/layout_tests/layouts/symlinked: -------------------------------------------------------------------------------- 1 | ../../symlink_parent -------------------------------------------------------------------------------- /actionpack/test/fixtures/override/test/hello_world.erb: -------------------------------------------------------------------------------- 1 | Hello overridden world! -------------------------------------------------------------------------------- /actionpack/test/fixtures/override2/layouts/test/sub.erb: -------------------------------------------------------------------------------- 1 | layout: <%= yield %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/post_test/super_post/index.iphone.erb: -------------------------------------------------------------------------------- 1 | Super iPhone -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/500.da.html: -------------------------------------------------------------------------------- 1 | 500 localized error fixture 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/javascripts/application.js: -------------------------------------------------------------------------------- 1 | // application js -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/javascripts/subdir/subdir.js: -------------------------------------------------------------------------------- 1 | // subdir js 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/javascripts/version.1.0.js: -------------------------------------------------------------------------------- 1 | // version.1.0 js -------------------------------------------------------------------------------- /actionpack/test/fixtures/quiz/questions/_question.html.erb: -------------------------------------------------------------------------------- 1 | <%= question.name %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/formatted_html_erb.html.erb: -------------------------------------------------------------------------------- 1 | formatted html erb -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/hello_world_with_layout_false.erb: -------------------------------------------------------------------------------- 1 | Hello world! -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/malformed/malformed.en.html.erb~: -------------------------------------------------------------------------------- 1 | Don't render me! -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/malformed/malformed.html.erb~: -------------------------------------------------------------------------------- 1 | Don't render me! -------------------------------------------------------------------------------- /activerecord/test/models/binary.rb: -------------------------------------------------------------------------------- 1 | class Binary < ActiveRecord::Base 2 | end -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/a/c/e/f.rb: -------------------------------------------------------------------------------- 1 | class A::C::E::F 2 | end -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/mailer/templates/view.rhtml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /railties/test/fixtures/lib/generators/missing_class/missing_class_generator.rb: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /railties/test/fixtures/lib/generators/missing_generator/templates/.gitignore: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /actionmailer/test/fixtures/explicit_layout_mailer/logout.html.erb: -------------------------------------------------------------------------------- 1 | You logged out -------------------------------------------------------------------------------- /actionmailer/test/fixtures/explicit_layout_mailer/signup.html.erb: -------------------------------------------------------------------------------- 1 | We do not spam -------------------------------------------------------------------------------- /actionmailer/test/fixtures/test_mailer/rxml_template.rxml: -------------------------------------------------------------------------------- 1 | xml.instruct! 2 | xml.test -------------------------------------------------------------------------------- /actionpack/test/controller/controller_fixtures/app/controllers/user_controller.rb: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/layout_tests/layouts/item.rhtml: -------------------------------------------------------------------------------- 1 | item.rhtml <%= yield %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/layout_tests/layouts/third_party_template_library.mab: -------------------------------------------------------------------------------- 1 | Mab -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/stylesheets/subdir/subdir.css: -------------------------------------------------------------------------------- 1 | /* subdir.css */ 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/stylesheets/version.1.0.css: -------------------------------------------------------------------------------- 1 | /* version.1.0.css */ -------------------------------------------------------------------------------- /actionpack/test/fixtures/respond_to/using_defaults.xml.builder: -------------------------------------------------------------------------------- 1 | xml.p "Hello world!" -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/greeting.js.rjs: -------------------------------------------------------------------------------- 1 | page[:body].visual_effect :highlight -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/greeting.registered.erb: -------------------------------------------------------------------------------- 1 | Registered mime type! 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/greeting.unregistered.erb: -------------------------------------------------------------------------------- 1 | Unregistered mime type! 2 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/fk_test_has_fk.yml: -------------------------------------------------------------------------------- 1 | first: 2 | id: 1 3 | fk_id: 1 4 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/items.yml: -------------------------------------------------------------------------------- 1 | dvd: 2 | id: 1 3 | name: Godfather 4 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/warehouse-things.yml: -------------------------------------------------------------------------------- 1 | one: 2 | id: 1 3 | value: 1000 -------------------------------------------------------------------------------- /activerecord/test/models/default.rb: -------------------------------------------------------------------------------- 1 | class Default < ActiveRecord::Base 2 | end 3 | -------------------------------------------------------------------------------- /activerecord/test/models/task.rb: -------------------------------------------------------------------------------- 1 | class Task < ActiveRecord::Base 2 | 3 | end 4 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/mailer/templates/fixture.rhtml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /railties/test/fixtures/about_yml_plugins/bad_about_yml/init.rb: -------------------------------------------------------------------------------- 1 | # intentionally empty -------------------------------------------------------------------------------- /railties/test/fixtures/eager/zoo.rb: -------------------------------------------------------------------------------- 1 | class Zoo 2 | include ReptileHouse 3 | end -------------------------------------------------------------------------------- /railties/test/fixtures/eager/zoo/reptile_house.rb: -------------------------------------------------------------------------------- 1 | module Zoo::ReptileHouse 2 | end -------------------------------------------------------------------------------- /railties/test/fixtures/plugins/default/acts/acts_as_chunky_bacon/lib/.gitignore: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /railties/test/fixtures/plugins/default/gemlike/lib/gemlike.rb: -------------------------------------------------------------------------------- 1 | module Gemlike 2 | end -------------------------------------------------------------------------------- /actionmailer/test/fixtures/auto_layout_mailer/multipart.text.html.erb: -------------------------------------------------------------------------------- 1 | text/html multipart -------------------------------------------------------------------------------- /actionmailer/test/fixtures/test_mailer/rxml_template.builder: -------------------------------------------------------------------------------- 1 | xml.instruct! 2 | xml.test -------------------------------------------------------------------------------- /actionpack/test/controller/controller_fixtures/app/controllers/admin/user_controller.rb: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/content_type/render_default_for_rxml.rxml: -------------------------------------------------------------------------------- 1 | xml.p "Hello world!" -------------------------------------------------------------------------------- /actionpack/test/fixtures/respond_to/using_defaults_with_type_list.html.erb: -------------------------------------------------------------------------------- 1 | Hello world! -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_labelling_form.erb: -------------------------------------------------------------------------------- 1 | <%= labelling_form.label :title %> 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_one.html.erb: -------------------------------------------------------------------------------- 1 | <%= render :partial => "two" %> world 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/implicit_content_type.atom.builder: -------------------------------------------------------------------------------- 1 | xml.atom do 2 | end 3 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/inspect_local_assigns.erb: -------------------------------------------------------------------------------- 1 | <%= local_assigns.inspect %> 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/render_file_with_ivar.erb: -------------------------------------------------------------------------------- 1 | The secret is <%= @secret %> 2 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/naked/yml/companies.yml: -------------------------------------------------------------------------------- 1 | # i wonder what will happen here 2 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/tees.yml: -------------------------------------------------------------------------------- 1 | awesome_tee: 2 | id: 1 3 | sucky_tee: 4 | id: 2 -------------------------------------------------------------------------------- /activerecord/test/fixtures/ties.yml: -------------------------------------------------------------------------------- 1 | awesome_tie: 2 | id: 1 3 | sucky_tie: 4 | id: 2 -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/application.rb: -------------------------------------------------------------------------------- 1 | ApplicationController = 10 2 | -------------------------------------------------------------------------------- /rack/bin/rackup: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | 3 | require "rack" 4 | Rack::Server.start 5 | -------------------------------------------------------------------------------- /railties/builtin/rails_info/rails/info_helper.rb: -------------------------------------------------------------------------------- 1 | module Rails::InfoHelper 2 | end 3 | -------------------------------------------------------------------------------- /actionmailer/test/fixtures/auto_layout_mailer/multipart.text.plain.erb: -------------------------------------------------------------------------------- 1 | text/plain multipart -------------------------------------------------------------------------------- /actionmailer/test/fixtures/layouts/auto_layout_mailer.html.erb: -------------------------------------------------------------------------------- 1 | Hello from layout <%= yield %> -------------------------------------------------------------------------------- /actionmailer/test/fixtures/test_mailer/body_ivar.erb: -------------------------------------------------------------------------------- 1 | body: <%= @body %> 2 | bar: <%= @bar %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/content_type/render_default_for_rhtml.rhtml: -------------------------------------------------------------------------------- 1 | <%= 'hello world!' %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/content_type/render_default_for_rjs.rjs: -------------------------------------------------------------------------------- 1 | page.alert 'hello world!' -------------------------------------------------------------------------------- /actionpack/test/fixtures/customers/_customer.html.erb: -------------------------------------------------------------------------------- 1 | <%= greeting %>: <%= customer.name %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/layout_tests/abs_path_layout.rhtml: -------------------------------------------------------------------------------- 1 | abs_path_layout.rhtml <%= yield %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/layout_tests/layouts/layout_test.rhtml: -------------------------------------------------------------------------------- 1 | layout_test.rhtml <%= yield %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/respond_to/custom_constant_handling_without_block.mobile.erb: -------------------------------------------------------------------------------- 1 | Mobile -------------------------------------------------------------------------------- /actionpack/test/fixtures/respond_to/using_defaults.js.rjs: -------------------------------------------------------------------------------- 1 | page[:body].visual_effect :highlight -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_customer.erb: -------------------------------------------------------------------------------- 1 | Hello: <%= customer.name rescue "Anonymous" %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/_person.erb: -------------------------------------------------------------------------------- 1 | Second: <%= name %> 2 | Third: <%= @name %> 3 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/formatted_xml_erb.xml.erb: -------------------------------------------------------------------------------- 1 |Dreamy days
3 | <% end %> 4 | <%= days %> 5 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/content_for.erb: -------------------------------------------------------------------------------- 1 | <% content_for :title do %>Putting stuff in the title!<% end %> 2 | Great stuff! -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/render_implicit_html_template.js.rjs: -------------------------------------------------------------------------------- 1 | page.call "document.write", render(:partial => "one") 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/topic.rb: -------------------------------------------------------------------------------- 1 | class Topic < ActiveRecord::Base 2 | has_many :replies, :dependent => :destroy 3 | end 4 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/organizations.yml: -------------------------------------------------------------------------------- 1 | nsa: 2 | name: No Such Agency 3 | discordians: 4 | name: Discordians 5 | 6 | -------------------------------------------------------------------------------- /activerecord/test/models/credential_usage.rb: -------------------------------------------------------------------------------- 1 | class CredentialUsage < ActiveRecord::Base 2 | belongs_to :credential 3 | end 4 | -------------------------------------------------------------------------------- /activerecord/test/models/legacy_thing.rb: -------------------------------------------------------------------------------- 1 | class LegacyThing < ActiveRecord::Base 2 | set_locking_column :version 3 | end 4 | -------------------------------------------------------------------------------- /activerecord/test/models/line_item.rb: -------------------------------------------------------------------------------- 1 | class LineItem < ActiveRecord::Base 2 | belongs_to :invoice, :touch => true 3 | end 4 | -------------------------------------------------------------------------------- /activerecord/test/models/reader.rb: -------------------------------------------------------------------------------- 1 | class Reader < ActiveRecord::Base 2 | belongs_to :post 3 | belongs_to :person 4 | end 5 | -------------------------------------------------------------------------------- /activerecord/test/models/zine.rb: -------------------------------------------------------------------------------- 1 | class Zine < ActiveRecord::Base 2 | has_many :interests, :inverse_of => :zine 3 | end 4 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/json.rb: -------------------------------------------------------------------------------- 1 | require 'active_support/json/decoding' 2 | require 'active_support/json/encoding' 3 | -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/class_folder.rb: -------------------------------------------------------------------------------- 1 | class ClassFolder 2 | ConstantInClassFolder = 'indeed' 3 | end 4 | -------------------------------------------------------------------------------- /rack/.gitignore: -------------------------------------------------------------------------------- 1 | RDOX 2 | ChangeLog 3 | *.gem 4 | lighttpd.errors 5 | *.rbc 6 | stage 7 | *.tar.gz 8 | .rbx 9 | doc 10 | -------------------------------------------------------------------------------- /rack/test/builder/comment.ru: -------------------------------------------------------------------------------- 1 | =begin 2 | 3 | =end 4 | run lambda { |env| [200, {'Content-Type' => 'text/plain'}, ['OK']] } 5 | -------------------------------------------------------------------------------- /rack/test/cgi/sample_rackup.ru: -------------------------------------------------------------------------------- 1 | # -*- ruby -*- 2 | 3 | require '../testrequest' 4 | 5 | run Rack::Lint.new(TestRequest.new) 6 | -------------------------------------------------------------------------------- /railties/guides/images/csrf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/csrf.png -------------------------------------------------------------------------------- /railties/guides/images/habtm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/habtm.png -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/controller/templates/helper.rb: -------------------------------------------------------------------------------- 1 | module <%= class_name %>Helper 2 | end 3 | -------------------------------------------------------------------------------- /actionmailer/test/fixtures/helper_mailer/use_helper_method.erb: -------------------------------------------------------------------------------- 1 | This message brought to you by <%= name_of_the_mailer_class %>. 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/functional_caching/fragment_cached.html.erb: -------------------------------------------------------------------------------- 1 | Hello 2 | <% cache do %>This bit's fragment cached<% end %> 3 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/functional_caching/js_fragment_cached_with_partial.js.rjs: -------------------------------------------------------------------------------- 1 | page.replace_html 'notices', :partial => 'partial' -------------------------------------------------------------------------------- /actionpack/test/fixtures/layouts/_column.html.erb: -------------------------------------------------------------------------------- 1 |<%=h @exception.message %>
3 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/functional_caching/formatted_fragment_cached.html.erb: -------------------------------------------------------------------------------- 1 | 2 | <% cache do %>ERB
<% end %> 3 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/layouts/talk_from_action.erb: -------------------------------------------------------------------------------- 1 |<%=h @exception.message %>
3 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/bad_customers/_bad_customer.html.erb: -------------------------------------------------------------------------------- 1 | <%= greeting %> bad customer: <%= bad_customer.name %><%= bad_customer_counter %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/project.rb: -------------------------------------------------------------------------------- 1 | class Project < ActiveRecord::Base 2 | has_and_belongs_to_many :developers, :uniq => true 3 | end 4 | -------------------------------------------------------------------------------- /activerecord/examples/associations.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/activerecord/examples/associations.png -------------------------------------------------------------------------------- /activerecord/test/fixtures/jobs.yml: -------------------------------------------------------------------------------- 1 | unicyclist: 2 | id: 1 3 | ideal_reference_id: 2 4 | clown: 5 | id: 2 6 | magician: 7 | id: 3 8 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/member_types.yml: -------------------------------------------------------------------------------- 1 | founding: 2 | id: 1 3 | name: Founding 4 | provisional: 5 | id: 2 6 | name: Provisional 7 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/reserved_words/values.yml: -------------------------------------------------------------------------------- 1 | values1: 2 | id: 1 3 | group_id: 2 4 | 5 | values2: 6 | id: 2 7 | group_id: 1 8 | -------------------------------------------------------------------------------- /activerecord/test/models/computer.rb: -------------------------------------------------------------------------------- 1 | class Computer < ActiveRecord::Base 2 | belongs_to :developer, :foreign_key=>'developer' 3 | end 4 | -------------------------------------------------------------------------------- /activerecord/test/models/contract.rb: -------------------------------------------------------------------------------- 1 | class Contract < ActiveRecord::Base 2 | belongs_to :company 3 | belongs_to :developer 4 | end 5 | 6 | -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/multiple_constant_file.rb: -------------------------------------------------------------------------------- 1 | MultipleConstantFile = 10 2 | SiblingConstant = MultipleConstantFile * 2 3 | -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/raises_no_method_error.rb: -------------------------------------------------------------------------------- 1 | class RaisesNoMethodError 2 | self.foobar_method_doesnt_exist 3 | end 4 | -------------------------------------------------------------------------------- /railties/bin/dbconsole: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require File.expand_path('../../config/boot', __FILE__) 3 | require 'commands/dbconsole' 4 | -------------------------------------------------------------------------------- /railties/guides/images/chapters_icon.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/chapters_icon.gif -------------------------------------------------------------------------------- /railties/guides/images/check_bullet.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/check_bullet.gif -------------------------------------------------------------------------------- /railties/guides/images/feature_tile.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/feature_tile.gif -------------------------------------------------------------------------------- /railties/guides/images/footer_tile.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/footer_tile.gif -------------------------------------------------------------------------------- /railties/guides/images/grey_bullet.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/grey_bullet.gif -------------------------------------------------------------------------------- /railties/guides/images/header_tile.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/header_tile.gif -------------------------------------------------------------------------------- /railties/guides/images/icons/caution.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/caution.png -------------------------------------------------------------------------------- /railties/guides/images/icons/example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/example.png -------------------------------------------------------------------------------- /railties/guides/images/icons/warning.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/warning.png -------------------------------------------------------------------------------- /railties/guides/images/polymorphic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/polymorphic.png -------------------------------------------------------------------------------- /railties/guides/images/posts_index.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/posts_index.png -------------------------------------------------------------------------------- /railties/guides/images/rails_welcome.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/rails_welcome.png -------------------------------------------------------------------------------- /actionpack/test/fixtures/good_customers/_good_customer.html.erb: -------------------------------------------------------------------------------- 1 | <%= greeting %> good customer: <%= good_customer.name %><%= good_customer_counter %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/helpers/abc_helper.rb: -------------------------------------------------------------------------------- 1 | module AbcHelper 2 | def bare_a() end 3 | def bare_b() end 4 | def bare_c() end 5 | end 6 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/multipart/bracketed_param: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="foo[baz]" 3 | 4 | bar 5 | --AaB03x-- 6 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/multipart/single_parameter: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="foo" 3 | 4 | bar 5 | --AaB03x-- 6 | -------------------------------------------------------------------------------- /activemodel/lib/active_model/callbacks.rb: -------------------------------------------------------------------------------- 1 | require 'active_model/core' 2 | 3 | module ActiveModel 4 | module Callbacks 5 | 6 | end 7 | end -------------------------------------------------------------------------------- /activerecord/test/fixtures/courses.yml: -------------------------------------------------------------------------------- 1 | ruby: 2 | id: 1 3 | name: Ruby Development 4 | 5 | java: 6 | id: 2 7 | name: Java Development 8 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/mixed_case_monkeys.yml: -------------------------------------------------------------------------------- 1 | first: 2 | monkeyID: 1 3 | fleaCount: 42 4 | second: 5 | monkeyID: 2 6 | fleaCount: 43 7 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/movies.yml: -------------------------------------------------------------------------------- 1 | first: 2 | movieid: 1 3 | name: Terminator 4 | 5 | second: 6 | movieid: 2 7 | name: Gladiator 8 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/owners.yml: -------------------------------------------------------------------------------- 1 | blackbeard: 2 | owner_id: 1 3 | name: blackbeard 4 | 5 | ashley: 6 | owner_id: 2 7 | name: ashley 8 | -------------------------------------------------------------------------------- /activerecord/test/models/essay.rb: -------------------------------------------------------------------------------- 1 | class Essay < ActiveRecord::Base 2 | belongs_to :writer, :primary_key => :name, :polymorphic => true 3 | end 4 | -------------------------------------------------------------------------------- /activerecord/test/models/polymorphic_price.rb: -------------------------------------------------------------------------------- 1 | class PolymorphicPrice < ActiveRecord::Base 2 | belongs_to :sellable, :polymorphic => true 3 | end -------------------------------------------------------------------------------- /activerecord/test/models/price_estimate.rb: -------------------------------------------------------------------------------- 1 | class PriceEstimate < ActiveRecord::Base 2 | belongs_to :estimate_of, :polymorphic => true 3 | end 4 | -------------------------------------------------------------------------------- /activerecord/test/models/subscription.rb: -------------------------------------------------------------------------------- 1 | class Subscription < ActiveRecord::Base 2 | belongs_to :subscriber 3 | belongs_to :book 4 | end 5 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/json/encoders/symbol.rb: -------------------------------------------------------------------------------- 1 | class Symbol 2 | def as_json(options = nil) #:nodoc: 3 | to_s 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /rack/test/builder/anything.rb: -------------------------------------------------------------------------------- 1 | class Anything 2 | def self.call(env) 3 | [200, {'Content-Type' => 'text/plain'}, ['OK']] 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /rack/test/cgi/rackup_stub.rb: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | # -*- ruby -*- 3 | 4 | $:.unshift '../../lib' 5 | require 'rack' 6 | Rack::Server.start 7 | -------------------------------------------------------------------------------- /railties/guides/images/error_messages.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/error_messages.png -------------------------------------------------------------------------------- /railties/guides/images/has_one_through.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/has_one_through.png -------------------------------------------------------------------------------- /railties/guides/images/header_backdrop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/header_backdrop.png -------------------------------------------------------------------------------- /railties/guides/images/icons/important.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/important.png -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/mailer/templates/fixture.erb: -------------------------------------------------------------------------------- 1 | <%= class_name %>#<%= action %> 2 | 3 | Find me in <%= path %> 4 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/mailer/templates/view.erb: -------------------------------------------------------------------------------- 1 | <%= class_name %>#<%= action %> 2 | 3 | Find me in <%= path %> 4 | -------------------------------------------------------------------------------- /activerecord/test/migrations/duplicate/3_foo.rb: -------------------------------------------------------------------------------- 1 | class Foo < ActiveRecord::Migration 2 | def self.up 3 | end 4 | 5 | def self.down 6 | end 7 | end -------------------------------------------------------------------------------- /activerecord/test/models/matey.rb: -------------------------------------------------------------------------------- 1 | class Matey < ActiveRecord::Base 2 | belongs_to :pirate 3 | belongs_to :target, :class_name => 'Pirate' 4 | end 5 | -------------------------------------------------------------------------------- /activerecord/test/models/polymorphic_design.rb: -------------------------------------------------------------------------------- 1 | class PolymorphicDesign < ActiveRecord::Base 2 | belongs_to :designable, :polymorphic => true 3 | end -------------------------------------------------------------------------------- /activerecord/test/models/subject.rb: -------------------------------------------------------------------------------- 1 | # used for OracleSynonymTest, see test/synonym_test_oci.rb 2 | # 3 | class Subject < ActiveRecord::Base 4 | end 5 | -------------------------------------------------------------------------------- /railties/builtin/rails_info/rails_info_controller.rb: -------------------------------------------------------------------------------- 1 | # Alias to ensure old public.html still works. 2 | RailsInfoController = Rails::InfoController 3 | -------------------------------------------------------------------------------- /railties/guides/images/credits_pic_blank.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/credits_pic_blank.gif -------------------------------------------------------------------------------- /railties/guides/images/has_many_through.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/has_many_through.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/1.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/10.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/11.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/12.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/13.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/14.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/14.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/15.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/15.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/2.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/3.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/4.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/5.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/6.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/7.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/8.png -------------------------------------------------------------------------------- /railties/guides/images/icons/callouts/9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/icons/callouts/9.png -------------------------------------------------------------------------------- /railties/guides/images/rails_guides_logo.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/rails_guides_logo.gif -------------------------------------------------------------------------------- /railties/guides/images/rails_logo_remix.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/rails_logo_remix.gif -------------------------------------------------------------------------------- /railties/guides/images/session_fixation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/session_fixation.png -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/observer/templates/observer.rb: -------------------------------------------------------------------------------- 1 | class <%= class_name %>Observer < ActiveRecord::Observer 2 | end 3 | -------------------------------------------------------------------------------- /actionmailer/test/fixtures/helper_mailer/use_mail_helper.erb: -------------------------------------------------------------------------------- 1 | From "Romeo and Juliet": 2 | 3 | <%= block_format @text %> 4 | 5 | Good ol' Shakespeare. 6 | -------------------------------------------------------------------------------- /actionmailer/test/fixtures/test_mailer/custom_templating_extension.text.html.haml: -------------------------------------------------------------------------------- 1 | %p Hello there, 2 | 3 | %p 4 | Mr. 5 | = @recipient 6 | from haml -------------------------------------------------------------------------------- /actionmailer/test/fixtures/test_mailer/custom_templating_extension.text.plain.haml: -------------------------------------------------------------------------------- 1 | %p Hello there, 2 | 3 | %p 4 | Mr. 5 | = @recipient 6 | from haml -------------------------------------------------------------------------------- /actionmailer/test/fixtures/test_mailer/implicitly_multipart_example.text.plain.erb: -------------------------------------------------------------------------------- 1 | Plain text to <%= @recipient %>. 2 | Plain text to <%= @recipient %>. 3 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/functional_caching/formatted_fragment_cached.xml.builder: -------------------------------------------------------------------------------- 1 | xml.body do 2 | cache do 3 | xml.p "Builder" 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/multipart/binary_file: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/actionpack/test/fixtures/multipart/binary_file -------------------------------------------------------------------------------- /actionpack/test/fixtures/multipart/mixed_files: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/actionpack/test/fixtures/multipart/mixed_files -------------------------------------------------------------------------------- /activesupport/test/empty_bool.rb: -------------------------------------------------------------------------------- 1 | class EmptyTrue 2 | def empty?() true; end 3 | end 4 | 5 | class EmptyFalse 6 | def empty?() false; end 7 | end 8 | 9 | -------------------------------------------------------------------------------- /railties/lib/console_with_helpers.rb: -------------------------------------------------------------------------------- 1 | def helper 2 | @helper ||= ApplicationController.helpers 3 | end 4 | 5 | @controller = ApplicationController.new 6 | -------------------------------------------------------------------------------- /Gemfile: -------------------------------------------------------------------------------- 1 | # this is only for building the gems and releasing them, see Gemfile.common for test setup 2 | 3 | source 'https://rubygems.org' 4 | 5 | gem 'rake' 6 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/multipart/mona_lisa.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/actionpack/test/fixtures/multipart/mona_lisa.jpg -------------------------------------------------------------------------------- /actionpack/test/fixtures/public/images/rails.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/actionpack/test/fixtures/public/images/rails.png -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/content_for_concatenated.erb: -------------------------------------------------------------------------------- 1 | <% content_for :title, "Putting stuff " 2 | content_for :title, "in the title!" %> 3 | Great stuff! -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/list.erb: -------------------------------------------------------------------------------- 1 | <%= @test_unchanged = 'goodbye' %><%= render :partial => 'customer', :collection => @customers %><%= @test_unchanged %> 2 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/non_erb_block_content_for.builder: -------------------------------------------------------------------------------- 1 | content_for :title do 2 | 'Putting stuff in the title!' 3 | end 4 | xml << "\nGreat stuff!" 5 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/using_layout_around_block_with_args.html.erb: -------------------------------------------------------------------------------- 1 | <% render(:layout => "layout_for_block_with_args") do |*args| %><%= args.join %><% end %> -------------------------------------------------------------------------------- /activerecord/test/fixtures/books.yml: -------------------------------------------------------------------------------- 1 | awdr: 2 | id: 1 3 | name: "Agile Web Development with Rails" 4 | 5 | rfr: 6 | id: 2 7 | name: "Ruby for Rails" 8 | -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/counting_loader.rb: -------------------------------------------------------------------------------- 1 | $counting_loaded_times ||= 0 2 | $counting_loaded_times += 1 3 | 4 | module CountingLoader 5 | end 6 | -------------------------------------------------------------------------------- /railties/guides/images/i18n/demo_translated_en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/i18n/demo_translated_en.png -------------------------------------------------------------------------------- /railties/guides/images/i18n/demo_untranslated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/i18n/demo_untranslated.png -------------------------------------------------------------------------------- /railties/test/fixtures/plugins/alternate/a/generators/a_generator/a_generator.rb: -------------------------------------------------------------------------------- 1 | class AGenerator < Rails::Generator::Base 2 | def manifest 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/projects.yml: -------------------------------------------------------------------------------- 1 | action_controller: 2 | id: 2 3 | name: Active Controller 4 | 5 | active_record: 6 | id: 1 7 | name: Active Record 8 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/projects.yml: -------------------------------------------------------------------------------- 1 | action_controller: 2 | id: 2 3 | name: Active Controller 4 | 5 | active_record: 6 | id: 1 7 | name: Active Record 8 | -------------------------------------------------------------------------------- /activerecord/test/models/categorization.rb: -------------------------------------------------------------------------------- 1 | class Categorization < ActiveRecord::Base 2 | belongs_to :post 3 | belongs_to :category 4 | belongs_to :author 5 | end -------------------------------------------------------------------------------- /activerecord/test/models/credential.rb: -------------------------------------------------------------------------------- 1 | require 'models/credential_usage' 2 | 3 | class Credential < ActiveRecord::Base 4 | has_many :credential_usages 5 | end 6 | -------------------------------------------------------------------------------- /activerecord/test/models/pet.rb: -------------------------------------------------------------------------------- 1 | class Pet < ActiveRecord::Base 2 | set_primary_key :pet_id 3 | belongs_to :owner, :touch => true 4 | has_many :toys 5 | end 6 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext/string/bytesize.rb: -------------------------------------------------------------------------------- 1 | unless '1.9'.respond_to?(:bytesize) 2 | class String 3 | alias :bytesize :size 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /rack/test/builder/end.ru: -------------------------------------------------------------------------------- 1 | run lambda { |env| [200, {'Content-Type' => 'text/plain'}, ['OK']] } 2 | __END__ 3 | Should not be evaluated 4 | Neither should 5 | This 6 | -------------------------------------------------------------------------------- /railties/bin/performance/profiler: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require File.expand_path('../../../config/boot', __FILE__) 3 | require 'commands/performance/profiler' 4 | -------------------------------------------------------------------------------- /railties/guides/images/customized_error_messages.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/customized_error_messages.png -------------------------------------------------------------------------------- /railties/guides/images/validation_error_messages.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/validation_error_messages.png -------------------------------------------------------------------------------- /railties/helpers/application_helper.rb: -------------------------------------------------------------------------------- 1 | # Methods added to this helper will be available to all templates in the application. 2 | module ApplicationHelper 3 | end 4 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/controller/templates/view.html.erb: -------------------------------------------------------------------------------- 1 |Find me in <%= path %>
3 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/resource/templates/controller.rb: -------------------------------------------------------------------------------- 1 | class <%= controller_class_name %>Controller < ApplicationController 2 | end 3 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/functional_caching/inline_fragment_cached.html.erb: -------------------------------------------------------------------------------- 1 | <%= render :inline => 'Some inline content' %> 2 | <% cache do %>Some cached content<% end %> 3 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/using_layout_around_block.html.erb: -------------------------------------------------------------------------------- 1 | <% render(:layout => "layout_for_partial", :locals => { :name => "David" }) do %>Inside from block<% end %> -------------------------------------------------------------------------------- /activerecord/test/fixtures/edges.yml: -------------------------------------------------------------------------------- 1 | <% (1..4).each do |id| %> 2 | edge_<%= id %>: 3 | id: <%= id %> 4 | source_id: <%= id %> 5 | sink_id: <%= id + 1 %> 6 | <% end %> -------------------------------------------------------------------------------- /activerecord/test/models/owner.rb: -------------------------------------------------------------------------------- 1 | class Owner < ActiveRecord::Base 2 | set_primary_key :owner_id 3 | has_many :pets 4 | has_many :toys, :through => :pets 5 | end 6 | -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/class_folder/class_folder_subclass.rb: -------------------------------------------------------------------------------- 1 | class ClassFolder::ClassFolderSubclass < ClassFolder 2 | ConstantInClassFolder 3 | end 4 | -------------------------------------------------------------------------------- /railties/bin/performance/benchmarker: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require File.expand_path('../../../config/boot', __FILE__) 3 | require 'commands/performance/benchmarker' 4 | -------------------------------------------------------------------------------- /railties/guides/images/i18n/demo_localized_pirate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/i18n/demo_localized_pirate.png -------------------------------------------------------------------------------- /railties/guides/images/i18n/demo_translated_pirate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/i18n/demo_translated_pirate.png -------------------------------------------------------------------------------- /activerecord/test/fixtures/members.yml: -------------------------------------------------------------------------------- 1 | groucho: 2 | name: Groucho Marx 3 | member_type_id: 1 4 | some_other_guy: 5 | name: Englebert Humperdink 6 | member_type_id: 2 7 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/subscribers.yml: -------------------------------------------------------------------------------- 1 | first: 2 | nick: alterself 3 | name: Luke Holden 4 | 5 | second: 6 | nick: webster132 7 | name: David Heinemeier Hansson 8 | -------------------------------------------------------------------------------- /activerecord/test/models/auto_id.rb: -------------------------------------------------------------------------------- 1 | class AutoId < ActiveRecord::Base 2 | def self.table_name () "auto_id_tests" end 3 | def self.primary_key () "auto_id" end 4 | end 5 | -------------------------------------------------------------------------------- /activerecord/test/models/tee.rb: -------------------------------------------------------------------------------- 1 | class Tee < ActiveRecord::Base 2 | has_one :polymorphic_design, :as => :designable 3 | has_one :polymorphic_price, :as => :sellable 4 | end -------------------------------------------------------------------------------- /activerecord/test/models/tie.rb: -------------------------------------------------------------------------------- 1 | class Tie < ActiveRecord::Base 2 | has_one :polymorphic_design, :as => :designable 3 | has_one :polymorphic_price, :as => :sellable 4 | end -------------------------------------------------------------------------------- /activerecord/test/models/warehouse_thing.rb: -------------------------------------------------------------------------------- 1 | class WarehouseThing < ActiveRecord::Base 2 | set_table_name "warehouse-things" 3 | 4 | validates_uniqueness_of :value 5 | end -------------------------------------------------------------------------------- /activesupport/test/autoloading_fixtures/class_folder/nested_class.rb: -------------------------------------------------------------------------------- 1 | class ClassFolder 2 | class NestedClass 3 | end 4 | 5 | class SiblingClass 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /rack/test/multipart/semicolon: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="files"; filename="fi;le1.txt" 3 | Content-Type: text/plain 4 | 5 | contents 6 | --AaB03x-- -------------------------------------------------------------------------------- /railties/guides/images/i18n/demo_translation_missing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/railties/guides/images/i18n/demo_translation_missing.png -------------------------------------------------------------------------------- /railties/test/fixtures/plugins/engines/engine/config/routes.rb: -------------------------------------------------------------------------------- 1 | ActionController::Routing::Routes.draw do |map| 2 | map.connect '/engine', :controller => "engine" 3 | end 4 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/readers.yml: -------------------------------------------------------------------------------- 1 | michael_welcome: 2 | id: 1 3 | post_id: 1 4 | person_id: 1 5 | 6 | michael_authorless: 7 | id: 2 8 | post_id: 3 9 | person_id: 1 -------------------------------------------------------------------------------- /activerecord/test/migrations/duplicate_names/20080507052938_chunky.rb: -------------------------------------------------------------------------------- 1 | class Chunky < ActiveRecord::Migration 2 | def self.up 3 | end 4 | 5 | def self.down 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /activerecord/test/migrations/duplicate_names/20080507053028_chunky.rb: -------------------------------------------------------------------------------- 1 | class Chunky < ActiveRecord::Migration 2 | def self.up 3 | end 4 | 5 | def self.down 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /activeresource/test/fixtures/proxy.rb: -------------------------------------------------------------------------------- 1 | class ProxyResource < ActiveResource::Base 2 | self.site = "http://localhost" 3 | self.proxy = "http://user:password@proxy.local:3000" 4 | end -------------------------------------------------------------------------------- /activesupport/lib/active_support/values/unicode_tables.dat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/genius/rails2/2-3-lts-for-genius/activesupport/lib/active_support/values/unicode_tables.dat -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/helper/templates/helper_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | 3 | class <%= class_name %>HelperTest < ActionView::TestCase 4 | end 5 | -------------------------------------------------------------------------------- /railties/test/fixtures/plugins/default/stubby/generators/stubby_generator/stubby_generator.rb: -------------------------------------------------------------------------------- 1 | class StubbyGenerator < Rails::Generator::Base 2 | def manifest 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/calling_partial_with_layout.html.erb: -------------------------------------------------------------------------------- 1 | <%= render(:layout => "layout_for_partial", :partial => "partial_for_use_in_layout", :locals => { :name => "David" }) %> -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/utf8.html.erb: -------------------------------------------------------------------------------- 1 | Русский <%= render :partial => 'test/utf8_partial' %> 2 | <%= "日".encoding %> 3 | <%= @output_buffer.encoding %> 4 | <%= __ENCODING__ %> 5 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/controller/templates/helper_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | 3 | class <%= class_name %>HelperTest < ActionView::TestCase 4 | end 5 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/plugin/templates/tasks.rake: -------------------------------------------------------------------------------- 1 | # desc "Explaining what the task does" 2 | # task :<%= file_name %> do 3 | # # Task goes here 4 | # end 5 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/authors.yml: -------------------------------------------------------------------------------- 1 | david: 2 | id: 1 3 | name: David 4 | author_address_id: 1 5 | author_address_extra_id: 2 6 | 7 | mary: 8 | id: 2 9 | name: Mary 10 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/mateys.yml: -------------------------------------------------------------------------------- 1 | blackbeard_to_redbeard: 2 | pirate_id: <%= Fixtures.identify(:blackbeard) %> 3 | target_id: <%= Fixtures.identify(:redbeard) %> 4 | weight: 10 5 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/price_estimates.yml: -------------------------------------------------------------------------------- 1 | saphire_1: 2 | price: 10 3 | estimate_of: sapphire (Treasure) 4 | 5 | sapphire_2: 6 | price: 20 7 | estimate_of: sapphire (Treasure) 8 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext/file.rb: -------------------------------------------------------------------------------- 1 | require 'active_support/core_ext/file/atomic' 2 | 3 | class File #:nodoc: 4 | extend ActiveSupport::CoreExtensions::File::Atomic 5 | end 6 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext/module/remove_method.rb: -------------------------------------------------------------------------------- 1 | class Module 2 | def remove_possible_method(method) 3 | remove_method(method) 4 | rescue NameError 5 | end 6 | end -------------------------------------------------------------------------------- /activesupport/test/dependencies/mutual_one.rb: -------------------------------------------------------------------------------- 1 | $mutual_dependencies_count += 1 2 | require_dependency 'mutual_two' 3 | require_dependency 'mutual_two.rb' 4 | require_dependency 'mutual_two' 5 | -------------------------------------------------------------------------------- /railties/bin/about: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require File.expand_path('../../config/boot', __FILE__) 3 | $LOAD_PATH.unshift "#{RAILTIES_PATH}/builtin/rails_info" 4 | require 'commands/about' 5 | -------------------------------------------------------------------------------- /actionmailer/test/fixtures/helpers/example_helper.rb: -------------------------------------------------------------------------------- 1 | module ExampleHelper 2 | def example_format(text) 3 | "#{h(text)}".html_safe 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /actionpack/lib/actionpack.rb: -------------------------------------------------------------------------------- 1 | require 'action_pack' 2 | ActiveSupport::Deprecation.warn 'require "actionpack" is deprecated and will be removed in Rails 3. Use require "action_pack" instead.' 3 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/nested_layout.erb: -------------------------------------------------------------------------------- 1 | <% content_for :title, "title" -%> 2 | <% content_for :column do -%>column<% end -%> 3 | <% render :layout => 'layouts/column' do -%>content<% end -%> -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/potential_conflicts.erb: -------------------------------------------------------------------------------- 1 | First: <%= @name %> 2 | <%= render :partial => "person", :locals => { :name => "Stephan" } -%> 3 | Fourth: <%= @name %> 4 | Fifth: <%= name %> -------------------------------------------------------------------------------- /activerecord/test/migrations/interleaved/pass_3/2_i_raise_on_down.rb: -------------------------------------------------------------------------------- 1 | class IRaiseOnDown < ActiveRecord::Migration 2 | def self.up 3 | end 4 | 5 | def self.down 6 | raise 7 | end 8 | end -------------------------------------------------------------------------------- /activerecord/test/models/member_detail.rb: -------------------------------------------------------------------------------- 1 | class MemberDetail < ActiveRecord::Base 2 | belongs_to :member 3 | belongs_to :organization 4 | has_one :member_type, :through => :member 5 | end 6 | -------------------------------------------------------------------------------- /activesupport/test/dependencies/mutual_two.rb: -------------------------------------------------------------------------------- 1 | $mutual_dependencies_count += 1 2 | require_dependency 'mutual_one.rb' 3 | require_dependency 'mutual_one' 4 | require_dependency 'mutual_one.rb' 5 | -------------------------------------------------------------------------------- /rack/test/multipart/content_type_and_no_filename: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="text" 3 | Content-Type: text/plain; charset=US-ASCII 4 | 5 | contents 6 | --AaB03x-- 7 | -------------------------------------------------------------------------------- /railties/html/javascripts/application.js: -------------------------------------------------------------------------------- 1 | // Place your application-specific JavaScript functions and classes here 2 | // This file is automatically included by javascript_include_tag :defaults 3 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/plugin/templates/test_helper.rb: -------------------------------------------------------------------------------- 1 | require 'rubygems' 2 | require 'test/unit' 3 | require 'active_support' 4 | require 'active_support/test_case' 5 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/resource/templates/helper_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | 3 | class <%= controller_class_name %>HelperTest < ActionView::TestCase 4 | end 5 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/scaffold/templates/helper_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | 3 | class <%= controller_class_name %>HelperTest < ActionView::TestCase 4 | end 5 | -------------------------------------------------------------------------------- /actionmailer/lib/action_mailer/utils.rb: -------------------------------------------------------------------------------- 1 | module ActionMailer 2 | module Utils #:nodoc: 3 | def normalize_new_lines(text) 4 | text.to_s.gsub(/\r\n?/, "\n") 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/categories/subsubdir/arbitrary_filename.yml: -------------------------------------------------------------------------------- 1 | sub_special_3: 2 | id: 102 3 | name: A special category in an arbitrarily named subsubdir file 4 | type: SpecialCategory 5 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/clubs.yml: -------------------------------------------------------------------------------- 1 | boring_club: 2 | name: Banana appreciation society 3 | moustache_club: 4 | name: Moustache and Eyebrow Fancier Club 5 | crazy_club: 6 | name: Skull and bones -------------------------------------------------------------------------------- /activerecord/test/models/item.rb: -------------------------------------------------------------------------------- 1 | class AbstractItem < ActiveRecord::Base 2 | self.abstract_class = true 3 | has_one :tagging, :as => :taggable 4 | end 5 | 6 | class Item < AbstractItem 7 | end 8 | -------------------------------------------------------------------------------- /activeresource/test/fixtures/street_address.rb: -------------------------------------------------------------------------------- 1 | class StreetAddress < ActiveResource::Base 2 | self.site = "http://37s.sunrise.i:3000/people/:person_id/" 3 | self.element_name = 'address' 4 | end 5 | -------------------------------------------------------------------------------- /rack/lib/rack/handler/evented_mongrel.rb: -------------------------------------------------------------------------------- 1 | require 'swiftcore/evented_mongrel' 2 | 3 | module Rack 4 | module Handler 5 | class EventedMongrel < Handler::Mongrel 6 | end 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /railties/test/fixtures/metal/multiplemetals/app/metal/metal_a.rb: -------------------------------------------------------------------------------- 1 | class MetalA < Rails::Rack::Metal 2 | def self.call(env) 3 | [200, { "Content-Type" => "text/html"}, ["Hi"]] 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /railties/test/fixtures/metal/multiplemetals/app/metal/metal_b.rb: -------------------------------------------------------------------------------- 1 | class MetalB < Rails::Rack::Metal 2 | def self.call(env) 3 | [200, { "Content-Type" => "text/html"}, ["Hi"]] 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /railties/test/fixtures/metal/singlemetal/app/metal/foo_metal.rb: -------------------------------------------------------------------------------- 1 | class FooMetal < Rails::Rack::Metal 2 | def self.call(env) 3 | [200, { "Content-Type" => "text/html"}, ["Hi"]] 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /Gemfile.lock: -------------------------------------------------------------------------------- 1 | GEM 2 | remote: https://rubygems.org/ 3 | specs: 4 | rake (13.0.6) 5 | 6 | PLATFORMS 7 | ruby 8 | 9 | DEPENDENCIES 10 | rake 11 | 12 | BUNDLED WITH 13 | 2.3.23 14 | -------------------------------------------------------------------------------- /actionmailer/lib/action_mailer/vendor/tmail-1.2.7/tmail/main.rb: -------------------------------------------------------------------------------- 1 | #:stopdoc: 2 | require 'tmail/version' 3 | require 'tmail/mail' 4 | require 'tmail/mailbox' 5 | require 'tmail/core_extensions' 6 | #:startdoc: -------------------------------------------------------------------------------- /actionmailer/lib/actionmailer.rb: -------------------------------------------------------------------------------- 1 | require 'action_mailer' 2 | ActiveSupport::Deprecation.warn 'require "actionmailer" is deprecated and will be removed in Rails 3. Use require "action_mailer" instead.' 3 | -------------------------------------------------------------------------------- /activerecord/lib/activerecord.rb: -------------------------------------------------------------------------------- 1 | require 'active_record' 2 | ActiveSupport::Deprecation.warn 'require "activerecord" is deprecated and will be removed in Rails 3. Use require "active_record" instead.' 3 | -------------------------------------------------------------------------------- /activerecord/test/models/event_author.rb: -------------------------------------------------------------------------------- 1 | require 'models/author' 2 | require 'models/event' 3 | 4 | class EventAuthor < ActiveRecord::Base 5 | belongs_to :author 6 | belongs_to :event 7 | end 8 | 9 | -------------------------------------------------------------------------------- /activesupport/test/dependencies/raises_exception.rb: -------------------------------------------------------------------------------- 1 | $raises_exception_load_count += 1 2 | raise Exception, 'Loading me failed, so do not add to loaded or history.' 3 | $raises_exception_load_count += 1 4 | -------------------------------------------------------------------------------- /railties/lib/commands/update.rb: -------------------------------------------------------------------------------- 1 | require "#{RAILS_ROOT}/config/environment" 2 | require 'rails_generator' 3 | require 'rails_generator/scripts/update' 4 | Rails::Generator::Scripts::Update.new.run(ARGV) 5 | -------------------------------------------------------------------------------- /actionmailer/test/fixtures/test_mailer/signed_up_with_url.erb: -------------------------------------------------------------------------------- 1 | Hello there, 2 | 3 | Mr. <%= @recipient %>. Please see our greeting at <%= @welcome_url %> <%= welcome_url %> 4 | 5 | <%= image_tag "somelogo.png" %> -------------------------------------------------------------------------------- /activemodel/lib/active_model.rb: -------------------------------------------------------------------------------- 1 | require 'active_model/observing' 2 | # disabled until they're tested 3 | # require 'active_model/callbacks' 4 | # require 'active_model/validations' 5 | require 'active_model/base' -------------------------------------------------------------------------------- /activerecord/test/fixtures/funny_jokes.yml: -------------------------------------------------------------------------------- 1 | a_joke: 2 | id: 1 3 | name: Knock knock 4 | 5 | another_joke: 6 | id: 2 7 | name: | 8 | The \n Aristocrats 9 | Ate the candy 10 | 11 | -------------------------------------------------------------------------------- /activerecord/test/models/invoice.rb: -------------------------------------------------------------------------------- 1 | class Invoice < ActiveRecord::Base 2 | has_many :line_items, :autosave => true 3 | before_save {|record| record.balance = record.line_items.map(&:amount).sum } 4 | end 5 | -------------------------------------------------------------------------------- /activerecord/test/models/job.rb: -------------------------------------------------------------------------------- 1 | class Job < ActiveRecord::Base 2 | has_many :references 3 | has_many :people, :through => :references 4 | belongs_to :ideal_reference, :class_name => 'Reference' 5 | end 6 | -------------------------------------------------------------------------------- /activerecord/test/models/sponsor.rb: -------------------------------------------------------------------------------- 1 | class Sponsor < ActiveRecord::Base 2 | belongs_to :sponsor_club, :class_name => "Club", :foreign_key => "club_id" 3 | belongs_to :sponsorable, :polymorphic => true 4 | end -------------------------------------------------------------------------------- /activerecord/test/models/toy.rb: -------------------------------------------------------------------------------- 1 | class Toy < ActiveRecord::Base 2 | set_primary_key :toy_id 3 | belongs_to :pet 4 | 5 | named_scope :with_name, lambda { |name| {:conditions => {:name => name}} } 6 | end 7 | -------------------------------------------------------------------------------- /activerecord/test/schema/schema2.rb: -------------------------------------------------------------------------------- 1 | ActiveRecord::Schema.define do 2 | 3 | Course.connection.create_table :courses, :force => true do |t| 4 | t.column :name, :string, :null => false 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /activesupport/lib/activesupport.rb: -------------------------------------------------------------------------------- 1 | require 'active_support' 2 | ActiveSupport::Deprecation.warn 'require "activesupport" is deprecated and will be removed in Rails 3. Use require "active_support" instead.' 3 | -------------------------------------------------------------------------------- /rack/lib/rack/handler/swiftiplied_mongrel.rb: -------------------------------------------------------------------------------- 1 | require 'swiftcore/swiftiplied_mongrel' 2 | 3 | module Rack 4 | module Handler 5 | class SwiftipliedMongrel < Handler::Mongrel 6 | end 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /railties/lib/rails/version.rb: -------------------------------------------------------------------------------- 1 | module Rails 2 | module VERSION #:nodoc: 3 | MAJOR = 2 4 | MINOR = 3 5 | TINY = 18 6 | 7 | STRING = [MAJOR, MINOR, TINY].join('.') 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /railties/test/fixtures/metal/pluralmetal/app/metal/legacy_routes.rb: -------------------------------------------------------------------------------- 1 | class LegacyRoutes < Rails::Rack::Metal 2 | def self.call(env) 3 | [301, { "Location" => "http://example.com"}, []] 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /activemodel/lib/active_model/base.rb: -------------------------------------------------------------------------------- 1 | module ActiveModel 2 | class Base 3 | include Observing 4 | # disabled, until they're tested 5 | # include Callbacks 6 | # include Validations 7 | end 8 | end -------------------------------------------------------------------------------- /activerecord/test/fixtures/treasures.yml: -------------------------------------------------------------------------------- 1 | diamond: 2 | name: $LABEL 3 | 4 | sapphire: 5 | name: $LABEL 6 | looter: redbeard (Pirate) 7 | 8 | ruby: 9 | name: $LABEL 10 | looter: louis (Parrot) 11 | -------------------------------------------------------------------------------- /activeresource/lib/activeresource.rb: -------------------------------------------------------------------------------- 1 | require 'active_resource' 2 | ActiveSupport::Deprecation.warn 'require "activeresource" is deprecated and will be removed in Rails 3. Use require "active_resource" instead.' 3 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/i18n-0.4.1/i18n/locale.rb: -------------------------------------------------------------------------------- 1 | module I18n 2 | module Locale 3 | autoload :Fallbacks, 'i18n/locale/fallbacks' 4 | autoload :Tag, 'i18n/locale/tag' 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /rack/test/cgi/test.fcgi: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | # -*- ruby -*- 3 | 4 | $:.unshift '../../lib' 5 | require 'rack' 6 | require '../testrequest' 7 | 8 | Rack::Handler::FastCGI.run(Rack::Lint.new(TestRequest.new)) 9 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/reply.rb: -------------------------------------------------------------------------------- 1 | class Reply < ActiveRecord::Base 2 | named_scope :base 3 | belongs_to :topic, :include => [:replies] 4 | belongs_to :developer 5 | 6 | validates_presence_of :content 7 | end 8 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/array_translation.erb: -------------------------------------------------------------------------------- 1 | <% translation = t(['translations.hello', 'translations.html', 'translations.hello_html']) %><%= translation.first %>, <%= translation.second %>, <%= translation.third %> -------------------------------------------------------------------------------- /activerecord/test/fixtures/credential_usages.yml: -------------------------------------------------------------------------------- 1 | first_credential_usage: 2 | id: 1 3 | credential_id: 1 4 | count: 1 5 | 6 | second_credential_usage: 7 | id: 2 8 | credential_id: 2 9 | count: 0 10 | -------------------------------------------------------------------------------- /activerecord/test/models/book.rb: -------------------------------------------------------------------------------- 1 | class Book < ActiveRecord::Base 2 | has_many :citations, :foreign_key => 'book1_id' 3 | has_many :references, :through => :citations, :source => :reference_of, :uniq => true 4 | end 5 | -------------------------------------------------------------------------------- /activerecord/test/models/organization.rb: -------------------------------------------------------------------------------- 1 | class Organization < ActiveRecord::Base 2 | has_many :member_details 3 | has_many :members, :through => :member_details 4 | 5 | named_scope :clubs, { :from => 'clubs' } 6 | end -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext/cgi.rb: -------------------------------------------------------------------------------- 1 | require 'active_support/core_ext/cgi/escape_skipping_slashes' 2 | 3 | class CGI #:nodoc: 4 | extend ActiveSupport::CoreExtensions::CGI::EscapeSkippingSlashes 5 | end 6 | -------------------------------------------------------------------------------- /rack/test/multipart/filename_with_escaped_quotes: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="files"; filename="escape \"quotes" 3 | Content-Type: application/octet-stream 4 | 5 | contents 6 | --AaB03x-- 7 | -------------------------------------------------------------------------------- /rack/test/multipart/filename_with_unescaped_quotes: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="files"; filename="escape "quotes" 3 | Content-Type: application/octet-stream 4 | 5 | contents 6 | --AaB03x-- 7 | -------------------------------------------------------------------------------- /rack/test/multipart/ie: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="files"; filename="C:\Documents and Settings\Administrator\Desktop\file1.txt" 3 | Content-Type: text/plain 4 | 5 | contents 6 | --AaB03x-- 7 | -------------------------------------------------------------------------------- /railties/test/fixtures/plugins/engines/engine/init.rb: -------------------------------------------------------------------------------- 1 | # My app/models dir must be in the load path. 2 | require 'engine_model' 3 | raise LoadError, 'missing model from my app/models dir' unless defined?(EngineModel) 4 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/utf8_magic.html.erb: -------------------------------------------------------------------------------- 1 | <%# encoding: utf-8 -%> 2 | Русский <%= render :partial => 'test/utf8_partial_magic' %> 3 | <%= "日".encoding %> 4 | <%= @output_buffer.encoding %> 5 | <%= __ENCODING__ %> 6 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext/base64.rb: -------------------------------------------------------------------------------- 1 | require 'active_support/base64' 2 | require 'active_support/core_ext/base64/encoding' 3 | 4 | ActiveSupport::Base64.extend ActiveSupport::CoreExtensions::Base64::Encoding 5 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/json/encoders/nil_class.rb: -------------------------------------------------------------------------------- 1 | class NilClass 2 | AS_JSON = ActiveSupport::JSON::Variable.new('null').freeze 3 | 4 | def as_json(options = nil) #:nodoc: 5 | AS_JSON 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/json/encoders/true_class.rb: -------------------------------------------------------------------------------- 1 | class TrueClass 2 | AS_JSON = ActiveSupport::JSON::Variable.new('true').freeze 3 | 4 | def as_json(options = nil) #:nodoc: 5 | AS_JSON 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /rack/example/protectedlobster.ru: -------------------------------------------------------------------------------- 1 | require 'rack/lobster' 2 | 3 | use Rack::ShowExceptions 4 | use Rack::Auth::Basic, "Lobster 2.0" do |username, password| 5 | 'secret' == password 6 | end 7 | 8 | run Rack::Lobster.new 9 | -------------------------------------------------------------------------------- /rack/test/multipart/none: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="submit-name" 3 | 4 | Larry 5 | --AaB03x 6 | Content-Disposition: form-data; name="files"; filename="" 7 | 8 | 9 | --AaB03x-- 10 | -------------------------------------------------------------------------------- /actionmailer/lib/action_mailer/version.rb: -------------------------------------------------------------------------------- 1 | module ActionMailer 2 | module VERSION #:nodoc: 3 | MAJOR = 2 4 | MINOR = 3 5 | TINY = 18 6 | 7 | STRING = [MAJOR, MINOR, TINY].join('.') 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /activerecord/lib/active_record/version.rb: -------------------------------------------------------------------------------- 1 | module ActiveRecord 2 | module VERSION #:nodoc: 3 | MAJOR = 2 4 | MINOR = 3 5 | TINY = 18 6 | 7 | STRING = [MAJOR, MINOR, TINY].join('.') 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/categories_ordered_primary_tag_handle.yml: -------------------------------------------------------------------------------- 1 | --- !omap 2 | <% 100.times do |i| %> 3 | - fixture_no_<%= i %>: 4 | id: <%= i %> 5 | name: <%= "Category #{i}" %> 6 | type: Category 7 | <% end %> 8 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/json/encoders/false_class.rb: -------------------------------------------------------------------------------- 1 | class FalseClass 2 | AS_JSON = ActiveSupport::JSON::Variable.new('false').freeze 3 | 4 | def as_json(options = nil) #:nodoc: 5 | AS_JSON 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/json/encoders/regexp.rb: -------------------------------------------------------------------------------- 1 | class Regexp 2 | def to_json(options = nil) #:nodoc: 3 | inspect 4 | end 5 | 6 | def as_json(options = nil) #:nodoc: 7 | self 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /rack/lib/rack/version.rb: -------------------------------------------------------------------------------- 1 | # frozen_string_literal: true 2 | 3 | module Rack 4 | RELEASE = "1.4.7.24" 5 | 6 | # Return the Rack release as a dotted string. 7 | def self.release 8 | RELEASE 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /rack/test/multipart/filename_with_percent_escaped_quotes: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="files"; filename="escape %22quotes" 3 | Content-Type: application/octet-stream 4 | 5 | contents 6 | --AaB03x-- 7 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/applications/app/scm/svn.rb: -------------------------------------------------------------------------------- 1 | module Rails 2 | class Svn < Scm 3 | def self.checkout(repos, branch = nil) 4 | `svn checkout #{repos}/#{branch || "trunk"}` 5 | end 6 | end 7 | end -------------------------------------------------------------------------------- /railties/lib/rails_generator/scripts/generate.rb: -------------------------------------------------------------------------------- 1 | require File.dirname(__FILE__) + '/../scripts' 2 | 3 | module Rails::Generator::Scripts 4 | class Generate < Base 5 | mandatory_options :command => :create 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /actionpack/lib/action_pack/version.rb: -------------------------------------------------------------------------------- 1 | module ActionPack #:nodoc: 2 | module VERSION #:nodoc: 3 | MAJOR = 2 4 | MINOR = 3 5 | TINY = 18 6 | 7 | STRING = [MAJOR, MINOR, TINY].join('.') 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/utf8_magic_with_bare_partial.html.erb: -------------------------------------------------------------------------------- 1 | <%# encoding: utf-8 -%> 2 | Русский <%= render :partial => 'test/utf8_partial' %> 3 | <%= "日".encoding %> 4 | <%= @output_buffer.encoding %> 5 | <%= __ENCODING__ %> 6 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/categories_ordered_secondary_tag_handle.yml: -------------------------------------------------------------------------------- 1 | --- !!omap 2 | <% 100.times do |i| %> 3 | - fixture_no_<%= i %>: 4 | id: <%= i %> 5 | name: <%= "Category #{i}" %> 6 | type: Category 7 | <% end %> 8 | -------------------------------------------------------------------------------- /activeresource/lib/active_resource/version.rb: -------------------------------------------------------------------------------- 1 | module ActiveResource 2 | module VERSION #:nodoc: 3 | MAJOR = 2 4 | MINOR = 3 5 | TINY = 18 6 | 7 | STRING = [MAJOR, MINOR, TINY].join('.') 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/version.rb: -------------------------------------------------------------------------------- 1 | module ActiveSupport 2 | module VERSION #:nodoc: 3 | MAJOR = 2 4 | MINOR = 3 5 | TINY = 18 6 | 7 | STRING = [MAJOR, MINOR, TINY].join('.') 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /rack/Gemfile: -------------------------------------------------------------------------------- 1 | source 'https://rubygems.org' 2 | 3 | gemspec 4 | 5 | # Rake 11+ is Ruby 1.9+ only. Stick with 10.x to avoid awkward Bundler 6 | # platform and RUBY_VERSION gymnastics, or separate Gemfiles. 7 | gem "rake", "< 11.0" 8 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/multipart/none: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="submit-name" 3 | 4 | Larry 5 | --AaB03x 6 | Content-Disposition: form-data; name="files"; filename="" 7 | 8 | 9 | --AaB03x-- 10 | -------------------------------------------------------------------------------- /railties/dispatches/config.ru: -------------------------------------------------------------------------------- 1 | # Rack Dispatcher 2 | 3 | # Require your environment file to bootstrap Rails 4 | require File.dirname(__FILE__) + '/config/environment' 5 | 6 | # Dispatch the request 7 | run ActionController::Dispatcher.new 8 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/controller/templates/controller.rb: -------------------------------------------------------------------------------- 1 | class <%= class_name %>Controller < ApplicationController 2 | <% for action in actions -%> 3 | def <%= action %> 4 | end 5 | 6 | <% end -%> 7 | end 8 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/metal/USAGE: -------------------------------------------------------------------------------- 1 | Description: 2 | Cast some metal! 3 | 4 | Examples: 5 | `./script/generate metal poller` 6 | 7 | This will create: 8 | Metal: app/metal/poller.rb 9 | -------------------------------------------------------------------------------- /railties/test/fixtures/metal/subfolders/app/metal/Folder/metal_a.rb: -------------------------------------------------------------------------------- 1 | module Folder 2 | class MetalA < Rails::Rack::Metal 3 | def self.call(env) 4 | [200, { "Content-Type" => "text/html"}, ["Hi"]] 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /railties/test/fixtures/metal/subfolders/app/metal/Folder/metal_b.rb: -------------------------------------------------------------------------------- 1 | module Folder 2 | class MetalB < Rails::Rack::Metal 3 | def self.call(env) 4 | [200, { "Content-Type" => "text/html"}, ["Hi"]] 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/hello_xml_world.builder: -------------------------------------------------------------------------------- 1 | xml.html do 2 | xml.head do 3 | xml.title "Hello World" 4 | end 5 | 6 | xml.body do 7 | xml.p "abes" 8 | xml.p "monks" 9 | xml.p "wiseguys" 10 | end 11 | end -------------------------------------------------------------------------------- /activerecord/test/models/membership.rb: -------------------------------------------------------------------------------- 1 | class Membership < ActiveRecord::Base 2 | belongs_to :member 3 | belongs_to :club 4 | end 5 | 6 | class CurrentMembership < Membership 7 | belongs_to :member 8 | belongs_to :club 9 | end 10 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext/pathname.rb: -------------------------------------------------------------------------------- 1 | require 'pathname' 2 | require 'active_support/core_ext/pathname/clean_within' 3 | 4 | class Pathname#:nodoc: 5 | extend ActiveSupport::CoreExtensions::Pathname::CleanWithin 6 | end 7 | 8 | -------------------------------------------------------------------------------- /railties/doc/README_FOR_APP: -------------------------------------------------------------------------------- 1 | Use this README file to introduce your application and point to useful places in the API for learning more. 2 | Run "rake doc:app" to generate API documentation for your models, controllers, helpers, and libraries. 3 | -------------------------------------------------------------------------------- /railties/html/robots.txt: -------------------------------------------------------------------------------- 1 | # See http://www.robotstxt.org/wc/norobots.html for documentation on how to use the robots.txt file 2 | # 3 | # To ban all spiders from the entire site uncomment the next two lines: 4 | # User-Agent: * 5 | # Disallow: / 6 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/pets.yml: -------------------------------------------------------------------------------- 1 | parrot: 2 | pet_id: 1 3 | name: parrot 4 | owner_id: 1 5 | 6 | chew: 7 | pet_id: 2 8 | name: chew 9 | owner_id: 2 10 | 11 | mochi: 12 | pet_id: 3 13 | name: mochi 14 | owner_id: 2 15 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/reserved_words/group.yml: -------------------------------------------------------------------------------- 1 | group1: 2 | id: 1 3 | select_id: 1 4 | order: x 5 | 6 | group2: 7 | id: 2 8 | select_id: 2 9 | order: y 10 | 11 | group3: 12 | id: 3 13 | select_id: 2 14 | order: z 15 | -------------------------------------------------------------------------------- /activerecord/test/models/subscriber.rb: -------------------------------------------------------------------------------- 1 | class Subscriber < ActiveRecord::Base 2 | set_primary_key 'nick' 3 | has_many :subscriptions 4 | has_many :books, :through => :subscriptions 5 | end 6 | 7 | class SpecialSubscriber < Subscriber 8 | end 9 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/model/templates/model.rb: -------------------------------------------------------------------------------- 1 | class <%= class_name %> < ActiveRecord::Base 2 | <% attributes.select(&:reference?).each do |attribute| -%> 3 | belongs_to :<%= attribute.name %> 4 | <% end -%> 5 | end 6 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/plugin/templates/USAGE: -------------------------------------------------------------------------------- 1 | Description: 2 | Explain the generator 3 | 4 | Example: 5 | ./script/generate <%= file_name %> Thing 6 | 7 | This will create: 8 | what/will/it/create 9 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/functional_caching/formatted_fragment_cached.js.rjs: -------------------------------------------------------------------------------- 1 | page.assign 'title', 'Hey' 2 | cache do 3 | page['element_1'].visual_effect :highlight 4 | page['element_2'].visual_effect :highlight 5 | end 6 | page.assign 'footer', 'Bye' 7 | -------------------------------------------------------------------------------- /rack/test/cgi/test: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | # -*- ruby -*- 3 | 4 | $: << File.join(File.dirname(__FILE__), "..", "..", "lib") 5 | 6 | require 'rack' 7 | require '../testrequest' 8 | 9 | Rack::Handler::CGI.run(Rack::Lint.new(TestRequest.new)) 10 | -------------------------------------------------------------------------------- /railties/lib/performance_test_help.rb: -------------------------------------------------------------------------------- 1 | require 'action_controller/performance_test' 2 | 3 | ActionController::Base.perform_caching = true 4 | ActiveSupport::Dependencies.mechanism = :require 5 | Rails.logger.level = ActiveSupport::BufferedLogger::INFO 6 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/test/enum_rjs_test.rjs: -------------------------------------------------------------------------------- 1 | page.select('.product').each do |value| 2 | page.visual_effect :highlight 3 | page.visual_effect :highlight, value 4 | page.sortable(value, :url => { :action => "order" }) 5 | page.draggable(value) 6 | end -------------------------------------------------------------------------------- /activerecord/test/fixtures/entrants.yml: -------------------------------------------------------------------------------- 1 | first: 2 | id: 1 3 | course_id: 1 4 | name: Ruby Developer 5 | 6 | second: 7 | id: 2 8 | course_id: 1 9 | name: Ruby Guru 10 | 11 | third: 12 | id: 3 13 | course_id: 2 14 | name: Java Lover 15 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/tasks.yml: -------------------------------------------------------------------------------- 1 | # Read about fixtures at http://ar.rubyonrails.org/classes/Fixtures.html 2 | first_task: 3 | id: 1 4 | starting: 2005-03-30t06:30:00.00+01:00 5 | ending: 2005-03-30t08:30:00.00+01:00 6 | another_task: 7 | id: 2 8 | -------------------------------------------------------------------------------- /railties/configs/locales/en.yml: -------------------------------------------------------------------------------- 1 | # Sample localization file for English. Add more files in this directory for other locales. 2 | # See http://github.com/svenfuchs/rails-i18n/tree/master/rails%2Flocale for starting points. 3 | 4 | en: 5 | hello: "Hello world" -------------------------------------------------------------------------------- /actionpack/lib/action_view/helpers/raw_output_helper.rb: -------------------------------------------------------------------------------- 1 | module ActionView #:nodoc: 2 | module Helpers #:nodoc: 3 | module RawOutputHelper 4 | def raw(stringish) 5 | stringish.to_s.html_safe 6 | end 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/faces.yml: -------------------------------------------------------------------------------- 1 | trusting: 2 | description: trusting 3 | man: gordon 4 | 5 | weather_beaten: 6 | description: weather beaten 7 | man: steve 8 | 9 | confused: 10 | description: confused 11 | polymorphic_man: gordon (Man) 12 | -------------------------------------------------------------------------------- /activerecord/test/models/order.rb: -------------------------------------------------------------------------------- 1 | class Order < ActiveRecord::Base 2 | belongs_to :billing, :class_name => 'Customer', :foreign_key => 'billing_customer_id' 3 | belongs_to :shipping, :class_name => 'Customer', :foreign_key => 'shipping_customer_id' 4 | end 5 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/json/encoders/string.rb: -------------------------------------------------------------------------------- 1 | class String 2 | def to_json(options = nil) #:nodoc: 3 | ActiveSupport::JSON::Encoding.escape(self) 4 | end 5 | 6 | def as_json(options = nil) #:nodoc: 7 | self 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /rack/test/multipart/empty: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="submit-name" 3 | 4 | Larry 5 | --AaB03x 6 | Content-Disposition: form-data; name="files"; filename="file1.txt" 7 | Content-Type: text/plain 8 | 9 | 10 | --AaB03x-- 11 | -------------------------------------------------------------------------------- /rack/test/registering_handler/rack/handler/registering_myself.rb: -------------------------------------------------------------------------------- 1 | require 'rack/handler' 2 | 3 | module Rack 4 | module Handler 5 | class RegisteringMyself 6 | end 7 | 8 | register :registering_myself, RegisteringMyself 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /railties/configs/initializers/mime_types.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # Add new mime types for use in respond_to blocks: 4 | # Mime::Type.register "text/richtext", :rtf 5 | # Mime::Type.register_alias "text/html", :iphone 6 | -------------------------------------------------------------------------------- /railties/lib/commands/destroy.rb: -------------------------------------------------------------------------------- 1 | require "#{RAILS_ROOT}/config/environment" 2 | require 'rails_generator' 3 | require 'rails_generator/scripts/destroy' 4 | 5 | ARGV.shift if ['--help', '-h'].include?(ARGV[0]) 6 | Rails::Generator::Scripts::Destroy.new.run(ARGV) 7 | -------------------------------------------------------------------------------- /actionpack/lib/action_controller/vendor/html-scanner/html/version.rb: -------------------------------------------------------------------------------- 1 | module HTML #:nodoc: 2 | module Version #:nodoc: 3 | 4 | MAJOR = 0 5 | MINOR = 5 6 | TINY = 3 7 | 8 | STRING = [ MAJOR, MINOR, TINY ].join(".") 9 | 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activerecord/test/config.rb: -------------------------------------------------------------------------------- 1 | TEST_ROOT = File.expand_path(File.dirname(__FILE__)) 2 | ASSETS_ROOT = TEST_ROOT + "/assets" 3 | FIXTURES_ROOT = TEST_ROOT + "/fixtures" 4 | MIGRATIONS_ROOT = TEST_ROOT + "/migrations" 5 | SCHEMA_ROOT = TEST_ROOT + "/schema" 6 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/pirates.yml: -------------------------------------------------------------------------------- 1 | blackbeard: 2 | catchphrase: "Yar." 3 | parrot: george 4 | 5 | redbeard: 6 | catchphrase: "Avast!" 7 | parrot: louis 8 | created_on: <%= 2.weeks.ago.to_s(:db) %> 9 | updated_on: <%= 2.weeks.ago.to_s(:db) %> 10 | -------------------------------------------------------------------------------- /activerecord/test/models/tag.rb: -------------------------------------------------------------------------------- 1 | class Tag < ActiveRecord::Base 2 | has_many :taggings 3 | has_many :taggables, :through => :taggings 4 | has_one :tagging 5 | 6 | has_many :tagged_posts, :through => :taggings, :source => :taggable, :source_type => 'Post' 7 | end -------------------------------------------------------------------------------- /activesupport/lib/active_support/multibyte/exceptions.rb: -------------------------------------------------------------------------------- 1 | # encoding: utf-8 2 | 3 | module ActiveSupport #:nodoc: 4 | module Multibyte #:nodoc: 5 | # Raised when a problem with the encoding was found. 6 | class EncodingError < StandardError; end 7 | end 8 | end -------------------------------------------------------------------------------- /rack/test/unregistered_handler/rack/handler/unregistered.rb: -------------------------------------------------------------------------------- 1 | require 'rack/handler' 2 | 3 | module Rack 4 | module Handler 5 | # this class doesn't do anything, we're just seeing if we get it. 6 | class Unregistered 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /railties/lib/commands/generate.rb: -------------------------------------------------------------------------------- 1 | require "#{RAILS_ROOT}/config/environment" 2 | require 'rails_generator' 3 | require 'rails_generator/scripts/generate' 4 | 5 | ARGV.shift if ['--help', '-h'].include?(ARGV[0]) 6 | Rails::Generator::Scripts::Generate.new.run(ARGV) 7 | -------------------------------------------------------------------------------- /railties/lib/rails/rack.rb: -------------------------------------------------------------------------------- 1 | module Rails 2 | module Rack 3 | autoload :Debugger, "rails/rack/debugger" 4 | autoload :LogTailer, "rails/rack/log_tailer" 5 | autoload :Metal, "rails/rack/metal" 6 | autoload :Static, "rails/rack/static" 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/reserved_words/distincts_selects.yml: -------------------------------------------------------------------------------- 1 | distincts_selects1: 2 | distinct_id: 1 3 | select_id: 1 4 | 5 | distincts_selects2: 6 | distinct_id: 1 7 | select_id: 2 8 | 9 | distincts_selects3: 10 | distinct_id: 2 11 | select_id: 3 12 | -------------------------------------------------------------------------------- /activerecord/test/migrations/valid/1_people_have_last_names.rb: -------------------------------------------------------------------------------- 1 | class PeopleHaveLastNames < ActiveRecord::Migration 2 | def self.up 3 | add_column "people", "last_name", :string 4 | end 5 | 6 | def self.down 7 | remove_column "people", "last_name" 8 | end 9 | end -------------------------------------------------------------------------------- /activerecord/test/models/interest.rb: -------------------------------------------------------------------------------- 1 | class Interest < ActiveRecord::Base 2 | belongs_to :man, :inverse_of => :interests 3 | belongs_to :polymorphic_man, :polymorphic => true, :inverse_of => :polymorphic_interests 4 | belongs_to :zine, :inverse_of => :interests 5 | end 6 | -------------------------------------------------------------------------------- /activerecord/test/models/treasure.rb: -------------------------------------------------------------------------------- 1 | class Treasure < ActiveRecord::Base 2 | has_and_belongs_to_many :parrots 3 | belongs_to :looter, :polymorphic => true 4 | 5 | has_many :price_estimates, :as => :estimate_of 6 | 7 | accepts_nested_attributes_for :looter 8 | end 9 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext/kernel/daemonizing.rb: -------------------------------------------------------------------------------- 1 | module Kernel 2 | # Turns the current script into a daemon process that detaches from the console. 3 | # It can be shut down with a TERM signal. 4 | def daemonize 5 | Process.daemon 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/model/templates/unit_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | 3 | class <%= class_name %>Test < ActiveSupport::TestCase 4 | # Replace this with your real tests. 5 | test "the truth" do 6 | assert true 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/plugin/templates/unit_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | 3 | class <%= class_name %>Test < ActiveSupport::TestCase 4 | # Replace this with your real tests. 5 | test "the truth" do 6 | assert true 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /railties/lib/tasks/log.rake: -------------------------------------------------------------------------------- 1 | namespace :log do 2 | desc "Truncates all *.log files in log/ to zero bytes" 3 | task :clear do 4 | FileList["log/*.log"].each do |log_file| 5 | f = File.open(log_file, "w") 6 | f.close 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /actionmailer/lib/action_mailer/vendor/tmail-1.2.7/tmail.rb: -------------------------------------------------------------------------------- 1 | require 'tmail/version' 2 | require 'tmail/mail' 3 | require 'tmail/mailbox' 4 | require 'tmail/core_extensions' 5 | require 'tmail/net' 6 | require 'tmail/vendor/rchardet-1.3/lib/rchardet' unless RUBY_VERSION >= '2' 7 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/multipart/empty: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="submit-name" 3 | 4 | Larry 5 | --AaB03x 6 | Content-Disposition: form-data; name="files"; filename="file1.txt" 7 | Content-Type: text/plain 8 | 9 | 10 | --AaB03x-- 11 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/multipart/text_file: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="foo" 3 | 4 | bar 5 | --AaB03x 6 | Content-Disposition: form-data; name="file"; filename="file.txt" 7 | Content-Type: text/plain 8 | 9 | contents 10 | --AaB03x-- 11 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/categories/special_categories.yml: -------------------------------------------------------------------------------- 1 | sub_special_1: 2 | id: 100 3 | name: A special category in a subdir file 4 | type: SpecialCategory 5 | 6 | sub_special_2: 7 | id: 101 8 | name: Another special category 9 | type: SpecialCategory 10 | -------------------------------------------------------------------------------- /activerecord/test/migrations/duplicate/1_people_have_last_names.rb: -------------------------------------------------------------------------------- 1 | class PeopleHaveLastNames < ActiveRecord::Migration 2 | def self.up 3 | add_column "people", "last_name", :string 4 | end 5 | 6 | def self.down 7 | remove_column "people", "last_name" 8 | end 9 | end -------------------------------------------------------------------------------- /activerecord/test/migrations/missing/1_people_have_last_names.rb: -------------------------------------------------------------------------------- 1 | class PeopleHaveLastNames < ActiveRecord::Migration 2 | def self.up 3 | add_column "people", "last_name", :string 4 | end 5 | 6 | def self.down 7 | remove_column "people", "last_name" 8 | end 9 | end -------------------------------------------------------------------------------- /activerecord/test/models/ship_part.rb: -------------------------------------------------------------------------------- 1 | class ShipPart < ActiveRecord::Base 2 | belongs_to :ship 3 | has_many :trinkets, :class_name => "Treasure", :as => :looter 4 | accepts_nested_attributes_for :trinkets, :allow_destroy => true 5 | 6 | validates_presence_of :name 7 | end -------------------------------------------------------------------------------- /activesupport/test/core_ext/object_ext_test.rb: -------------------------------------------------------------------------------- 1 | require 'abstract_unit' 2 | 3 | class ObjectExtTest < Test::Unit::TestCase 4 | def test_tap_yields_and_returns_self 5 | foo = Object.new 6 | assert_equal foo, foo.tap { |x| assert_equal foo, x; :bar } 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /rack/test/multipart/filename_with_unescaped_percentages2: -------------------------------------------------------------------------------- 1 | ------WebKitFormBoundary2NHc7OhsgU68l3Al 2 | Content-Disposition: form-data; name="document[attachment]"; filename="100%a" 3 | Content-Type: image/jpeg 4 | 5 | contents 6 | ------WebKitFormBoundary2NHc7OhsgU68l3Al-- 7 | -------------------------------------------------------------------------------- /rack/test/multipart/filename_with_unescaped_percentages3: -------------------------------------------------------------------------------- 1 | ------WebKitFormBoundary2NHc7OhsgU68l3Al 2 | Content-Disposition: form-data; name="document[attachment]"; filename="100%" 3 | Content-Type: image/jpeg 4 | 5 | contents 6 | ------WebKitFormBoundary2NHc7OhsgU68l3Al-- 7 | -------------------------------------------------------------------------------- /railties/guides/images/icons/README: -------------------------------------------------------------------------------- 1 | Replaced the plain DocBook XSL admonition icons with Jimmac's DocBook 2 | icons (http://jimmac.musichall.cz/ikony.php3). I dropped transparency 3 | from the Jimmac icons to get round MS IE and FOP PNG incompatibilies. 4 | 5 | Stuart Rackham 6 | -------------------------------------------------------------------------------- /activemodel/Rakefile: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require 'rake' 3 | require 'rake/testtask' 4 | 5 | task :default => :test 6 | 7 | Rake::TestTask.new do |t| 8 | t.libs << "test" 9 | t.pattern = 'test/**/*_test.rb' 10 | t.verbose = true 11 | t.warning = false 12 | end 13 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/categories.yml: -------------------------------------------------------------------------------- 1 | general: 2 | id: 1 3 | name: General 4 | type: Category 5 | 6 | technology: 7 | id: 2 8 | name: Technology 9 | type: Category 10 | 11 | sti_test: 12 | id: 3 13 | name: Special category 14 | type: SpecialCategory 15 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/subscriptions.yml: -------------------------------------------------------------------------------- 1 | webster_awdr: 2 | id: 1 3 | subscriber_id: webster132 4 | book_id: 1 5 | webster_rfr: 6 | id: 2 7 | subscriber_id: webster132 8 | book_id: 2 9 | alterself_awdr: 10 | id: 3 11 | subscriber_id: alterself 12 | book_id: 3 -------------------------------------------------------------------------------- /activerecord/test/models/edge.rb: -------------------------------------------------------------------------------- 1 | # This class models an edge in a directed graph. 2 | class Edge < ActiveRecord::Base 3 | belongs_to :source, :class_name => 'Vertex', :foreign_key => 'source_id' 4 | belongs_to :sink, :class_name => 'Vertex', :foreign_key => 'sink_id' 5 | end 6 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext/blank.rb: -------------------------------------------------------------------------------- 1 | require 'active_support/core_ext/object/blank' 2 | ActiveSupport::Deprecation.warn 'require "active_support/core_ext/blank" is deprecated and will be removed in Rails 3. Use require "active_support/core_ext/object/blank" instead.' 3 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/testing/default.rb: -------------------------------------------------------------------------------- 1 | module ActiveSupport 2 | module Testing 3 | module Default #:nodoc: 4 | # Placeholder so test/unit ignores test cases without any tests. 5 | def default_test 6 | end 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /rack/test/multipart/content_id: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data 3 | Content-ID: name-via-content-id 4 | 5 | Larry 6 | --AaB03x 7 | Content-Disposition: form-data; name="name-via-disposition" 8 | Content-Type: text/plain 9 | 10 | Berry 11 | --AaB03x-- 12 | -------------------------------------------------------------------------------- /rack/test/multipart/nested: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Disposition: form-data; name="foo[submit-name]" 3 | 4 | Larry 5 | --AaB03x 6 | Content-Disposition: form-data; name="foo[files]"; filename="file1.txt" 7 | Content-Type: text/plain 8 | 9 | contents 10 | --AaB03x-- 11 | -------------------------------------------------------------------------------- /rack/test/unregistered_handler/rack/handler/unregistered_long_one.rb: -------------------------------------------------------------------------------- 1 | require 'rack/handler' 2 | 3 | module Rack 4 | module Handler 5 | # this class doesn't do anything, we're just seeing if we get it. 6 | class UnregisteredLongOne 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/observer/templates/unit_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | 3 | class <%= class_name %>ObserverTest < ActiveSupport::TestCase 4 | # Replace this with your real tests. 5 | test "the truth" do 6 | assert true 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /actionmailer/lib/action_mailer/vendor/tmail-1.2.7/tmail/index.rb: -------------------------------------------------------------------------------- 1 | #:stopdoc: 2 | # This is here for Rolls. 3 | # Rolls uses this instead of lib/tmail.rb. 4 | 5 | require 'tmail/version' 6 | require 'tmail/mail' 7 | require 'tmail/mailbox' 8 | require 'tmail/core_extensions' 9 | #:startdoc: -------------------------------------------------------------------------------- /actionpack/test/fixtures/developer.rb: -------------------------------------------------------------------------------- 1 | class Developer < ActiveRecord::Base 2 | has_and_belongs_to_many :projects 3 | has_many :replies 4 | has_many :topics, :through => :replies 5 | end 6 | 7 | class DeVeLoPeR < ActiveRecord::Base 8 | set_table_name "developers" 9 | end 10 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/session_autoload_test/session_autoload_test/foo.rb: -------------------------------------------------------------------------------- 1 | module SessionAutoloadTest 2 | class Foo 3 | def initialize(bar='baz') 4 | @bar = bar 5 | end 6 | def inspect 7 | "#<#{self.class} bar:#{@bar.inspect}>" 8 | end 9 | end 10 | end -------------------------------------------------------------------------------- /activerecord/test/fixtures/credentials.yml: -------------------------------------------------------------------------------- 1 | first_credential: 2 | id: 1 3 | active: true 4 | credential_usages: "some" 5 | credentials: "password" 6 | 7 | second_credential: 8 | id: 2 9 | active: false 10 | credential_usages: "none" 11 | credentials: "foobar" 12 | -------------------------------------------------------------------------------- /activerecord/test/migrations/interleaved/pass_2/1_people_have_last_names.rb: -------------------------------------------------------------------------------- 1 | class PeopleHaveLastNames < ActiveRecord::Migration 2 | def self.up 3 | add_column "people", "last_name", :string 4 | end 5 | 6 | def self.down 7 | remove_column "people", "last_name" 8 | end 9 | end -------------------------------------------------------------------------------- /activerecord/test/migrations/interleaved/pass_3/1_people_have_last_names.rb: -------------------------------------------------------------------------------- 1 | class PeopleHaveLastNames < ActiveRecord::Migration 2 | def self.up 3 | add_column "people", "last_name", :string 4 | end 5 | 6 | def self.down 7 | remove_column "people", "last_name" 8 | end 9 | end -------------------------------------------------------------------------------- /activerecord/test/migrations/missing/1000_people_have_middle_names.rb: -------------------------------------------------------------------------------- 1 | class PeopleHaveMiddleNames < ActiveRecord::Migration 2 | def self.up 3 | add_column "people", "middle_name", :string 4 | end 5 | 6 | def self.down 7 | remove_column "people", "middle_name" 8 | end 9 | end -------------------------------------------------------------------------------- /activesupport/test/gzip_test.rb: -------------------------------------------------------------------------------- 1 | require 'abstract_unit' 2 | 3 | class GzipTest < Test::Unit::TestCase 4 | def test_compress_should_decompress_to_the_same_value 5 | assert_equal "Hello World", ActiveSupport::Gzip.decompress(ActiveSupport::Gzip.compress("Hello World")) 6 | end 7 | end -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/applications/app/scm/scm.rb: -------------------------------------------------------------------------------- 1 | module Rails 2 | class Scm 3 | private 4 | def self.hash_to_parameters(hash) 5 | hash.collect { |key, value| "--#{key} #{(value.kind_of?(String) ? value : "")}"}.join(" ") 6 | end 7 | end 8 | end -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/plugin/templates/generator.rb: -------------------------------------------------------------------------------- 1 | class <%= class_name %>Generator < Rails::Generator::NamedBase 2 | def manifest 3 | record do |m| 4 | # m.directory "lib" 5 | # m.template 'README', "README" 6 | end 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/json/variable.rb: -------------------------------------------------------------------------------- 1 | module ActiveSupport 2 | module JSON 3 | # A string that returns itself as its JSON-encoded form. 4 | class Variable < String 5 | def to_json(options=nil) 6 | self 7 | end 8 | end 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /rack/test/multipart/filename_with_unescaped_percentages: -------------------------------------------------------------------------------- 1 | ------WebKitFormBoundary2NHc7OhsgU68l3Al 2 | Content-Disposition: form-data; name="document[attachment]"; filename="100% of a photo.jpeg" 3 | Content-Type: image/jpeg 4 | 5 | contents 6 | ------WebKitFormBoundary2NHc7OhsgU68l3Al-- 7 | -------------------------------------------------------------------------------- /railties/lib/console_sandbox.rb: -------------------------------------------------------------------------------- 1 | ActiveRecord::Base.connection.increment_open_transactions 2 | ActiveRecord::Base.connection.begin_db_transaction 3 | at_exit do 4 | ActiveRecord::Base.connection.rollback_db_transaction 5 | ActiveRecord::Base.connection.decrement_open_transactions 6 | end 7 | -------------------------------------------------------------------------------- /activerecord/test/models/bird.rb: -------------------------------------------------------------------------------- 1 | class Bird < ActiveRecord::Base 2 | validates_presence_of :name 3 | 4 | attr_accessor :cancel_save_from_callback 5 | before_save :cancel_save_callback_method, :if => :cancel_save_from_callback 6 | def cancel_save_callback_method 7 | false 8 | end 9 | end -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext.rb: -------------------------------------------------------------------------------- 1 | filenames = Dir["#{File.dirname(__FILE__)}/core_ext/*.rb"].sort.map do |path| 2 | File.basename(path, '.rb') 3 | end 4 | 5 | # deprecated 6 | filenames -= %w(blank) 7 | 8 | filenames.each { |filename| require "active_support/core_ext/#{filename}" } 9 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/GMT.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module GMT 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'GMT', 'Etc/GMT' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/UCT.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module UCT 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'UCT', 'Etc/UCT' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/UTC.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module UTC 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'UTC', 'Etc/UTC' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/controller/templates/functional_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | 3 | class <%= class_name %>ControllerTest < ActionController::TestCase 4 | # Replace this with your real tests. 5 | test "the truth" do 6 | assert true 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /actionmailer/lib/action_mailer/vendor/text_format.rb: -------------------------------------------------------------------------------- 1 | # Prefer gems to the bundled libs. 2 | require 'rubygems' 3 | 4 | begin 5 | gem 'text-format', '>= 0.6.3' 6 | rescue Gem::LoadError 7 | $:.unshift "#{File.dirname(__FILE__)}/text-format-0.6.3" 8 | end 9 | 10 | require 'text/format' 11 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/parrots_pirates.yml: -------------------------------------------------------------------------------- 1 | george_blackbeard: 2 | parrot_id: <%= Fixtures.identify(:george) %> 3 | pirate_id: <%= Fixtures.identify(:blackbeard) %> 4 | 5 | louis_blackbeard: 6 | parrot_id: <%= Fixtures.identify(:louis) %> 7 | pirate_id: <%= Fixtures.identify(:blackbeard) %> 8 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext/float.rb: -------------------------------------------------------------------------------- 1 | require 'active_support/core_ext/float/rounding' 2 | require 'active_support/core_ext/float/time' 3 | 4 | class Float #:nodoc: 5 | include ActiveSupport::CoreExtensions::Float::Rounding 6 | include ActiveSupport::CoreExtensions::Float::Time 7 | end 8 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/GB.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module GB 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'GB', 'Europe/London' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/GMT0.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module GMT0 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'GMT0', 'Etc/GMT' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Iran.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Iran 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Iran', 'Asia/Tehran' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/NZ.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module NZ 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'NZ', 'Pacific/Auckland' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/PRC.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module PRC 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'PRC', 'Asia/Shanghai' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/ROC.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module ROC 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'ROC', 'Asia/Taipei' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/ROK.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module ROK 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'ROK', 'Asia/Seoul' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Zulu.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Zulu 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Zulu', 'Etc/UTC' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /railties/guides/files/javascripts/guides.js: -------------------------------------------------------------------------------- 1 | function guideMenu(){ 2 | 3 | if (document.getElementById('guides').style.display == "none") { 4 | document.getElementById('guides').style.display = "block"; 5 | } else { 6 | document.getElementById('guides').style.display = "none"; 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /railties/helpers/performance_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | require 'performance_test_help' 3 | 4 | # Profiling results for each test method are written to tmp/performance. 5 | class BrowsingTest < ActionController::PerformanceTest 6 | def test_homepage 7 | get '/' 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/resource/templates/functional_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | 3 | class <%= controller_class_name %>ControllerTest < ActionController::TestCase 4 | # Replace this with your real tests. 5 | test "the truth" do 6 | assert true 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /railties/lib/tasks/middleware.rake: -------------------------------------------------------------------------------- 1 | desc 'Prints out your Rack middleware stack' 2 | task :middleware => :environment do 3 | ActionController::Dispatcher.middleware.active.each do |middleware| 4 | puts "use #{middleware.inspect}" 5 | end 6 | puts "run ActionController::Dispatcher.new" 7 | end 8 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Cuba.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Cuba 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Cuba', 'America/Havana' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Egypt.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Egypt 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Egypt', 'Africa/Cairo' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Eire.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Eire 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Eire', 'Europe/Dublin' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Japan.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Japan 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Japan', 'Asia/Tokyo' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/metal/metal_generator.rb: -------------------------------------------------------------------------------- 1 | class MetalGenerator < Rails::Generator::NamedBase 2 | def manifest 3 | record do |m| 4 | m.directory 'app/metal' 5 | m.template 'metal.rb', File.join('app/metal', "#{file_name}.rb") 6 | end 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /activerecord/test/models/citation.rb: -------------------------------------------------------------------------------- 1 | class Citation < ActiveRecord::Base 2 | belongs_to :reference_of, :class_name => "Book", :foreign_key => :book2_id 3 | 4 | belongs_to :book1, :class_name => "Book", :foreign_key => :book1_id 5 | belongs_to :book2, :class_name => "Book", :foreign_key => :book2_id 6 | end 7 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/GMT__m__0.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module GMT__m__0 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'GMT-0', 'Etc/GMT' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/GMT__p__0.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module GMT__p__0 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'GMT+0', 'Etc/GMT' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Israel.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Israel 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Israel', 'Asia/Jerusalem' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Libya.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Libya 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Libya', 'Africa/Tripoli' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Navajo.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Navajo 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Navajo', 'America/Denver' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Poland.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Poland 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Poland', 'Europe/Warsaw' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Turkey.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Turkey 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Turkey', 'Europe/Istanbul' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/W__m__SU.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module W__m__SU 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'W-SU', 'Europe/Moscow' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/layouts/partial_with_layout.erb: -------------------------------------------------------------------------------- 1 | <%= render( :layout => "layout_for_partial", :partial => "partial_for_use_in_layout", :locals => {:name => 'Anthony' } ) %> 2 | <%= yield %> 3 | <%= render( :layout => "layout_for_partial", :partial => "partial_for_use_in_layout", :locals => {:name => 'Ramm' } ) %> -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Greenwich.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Greenwich 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Greenwich', 'Etc/GMT' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Hongkong.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Hongkong 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Hongkong', 'Asia/Hong_Kong' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Jamaica.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Jamaica 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Jamaica', 'America/Jamaica' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Portugal.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Portugal 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Portugal', 'Europe/Lisbon' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Universal.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Universal 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Universal', 'Etc/UTC' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /rack/test/multipart/filename_and_modification_param: -------------------------------------------------------------------------------- 1 | --AaB03x 2 | Content-Type: image/jpeg 3 | Content-Disposition: attachment; name="files"; filename=genome.jpeg; modification-date="Wed, 12 Feb 1997 16:29:51 -0500"; 4 | Content-Description: a complete map of the human genome 5 | 6 | contents 7 | --AaB03x-- 8 | -------------------------------------------------------------------------------- /actionpack/test/fixtures/company.rb: -------------------------------------------------------------------------------- 1 | class Company < ActiveRecord::Base 2 | has_one :mascot 3 | attr_protected :rating 4 | set_sequence_name :companies_nonstd_seq 5 | 6 | validates_presence_of :name 7 | def validate 8 | errors.add('rating', 'rating should not be 2') if rating == 2 9 | end 10 | end -------------------------------------------------------------------------------- /actionpack/test/fixtures/developers_projects.yml: -------------------------------------------------------------------------------- 1 | david_action_controller: 2 | developer_id: 1 3 | project_id: 2 4 | joined_on: 2004-10-10 5 | 6 | david_active_record: 7 | developer_id: 1 8 | project_id: 1 9 | joined_on: 2004-10-10 10 | 11 | jamis_active_record: 12 | developer_id: 2 13 | project_id: 1 -------------------------------------------------------------------------------- /activerecord/test/fixtures/people.yml: -------------------------------------------------------------------------------- 1 | michael: 2 | id: 1 3 | first_name: Michael 4 | primary_contact_id: 2 5 | gender: M 6 | david: 7 | id: 2 8 | first_name: David 9 | primary_contact_id: 3 10 | gender: M 11 | susan: 12 | id: 3 13 | first_name: Susan 14 | primary_contact_id: 2 15 | gender: F -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext/kernel.rb: -------------------------------------------------------------------------------- 1 | require 'active_support/core_ext/kernel/daemonizing' 2 | require 'active_support/core_ext/kernel/reporting' 3 | require 'active_support/core_ext/kernel/agnostics' 4 | require 'active_support/core_ext/kernel/requires' 5 | require 'active_support/core_ext/kernel/debugger' 6 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/GB__m__Eire.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module GB__m__Eire 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'GB-Eire', 'Europe/London' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Iceland.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Iceland 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Iceland', 'Atlantic/Reykjavik' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Singapore.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Singapore 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Singapore', 'Asia/Singapore' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /actionmailer/test/fixtures/test_mailer/implicitly_multipart_example.text.html.erb: -------------------------------------------------------------------------------- 1 | 2 | 3 | HTML formatted message to <%= @recipient %>. 4 | 5 | 6 | 7 | 8 | HTML formatted message to <%= @recipient %>. 9 | 10 | 11 | -------------------------------------------------------------------------------- /actionmailer/test/fixtures/test_mailer/implicitly_multipart_example.text.html.erb~: -------------------------------------------------------------------------------- 1 | 2 | 3 | HTML formatted message to <%= @recipient %>. 4 | 5 | 6 | 7 | 8 | HTML formatted message to <%= @recipient %>. 9 | 10 | 11 | -------------------------------------------------------------------------------- /actionpack/lib/action_controller/translation.rb: -------------------------------------------------------------------------------- 1 | module ActionController 2 | module Translation 3 | def translate(*args) 4 | I18n.translate(*args) 5 | end 6 | alias :t :translate 7 | 8 | def localize(*args) 9 | I18n.localize(*args) 10 | end 11 | alias :l :localize 12 | end 13 | end -------------------------------------------------------------------------------- /actionpack/test/fixtures/layouts/block_with_layout.erb: -------------------------------------------------------------------------------- 1 | <% render(:layout => "layout_for_partial", :locals => { :name => "Anthony" }) do %>Inside from first block in layout<% end %> 2 | <%= yield %> 3 | <% render(:layout => "layout_for_partial", :locals => { :name => "Ramm" }) do %>Inside from second block in layout<% end %> 4 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/Kwajalein.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module Kwajalein 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'Kwajalein', 'Pacific/Kwajalein' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/vendor/tzinfo-0.3.53/tzinfo/definitions/NZ__m__CHAT.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | 3 | module TZInfo 4 | module Definitions 5 | module NZ__m__CHAT 6 | include TimezoneDefinition 7 | 8 | linked_timezone 'NZ-CHAT', 'Pacific/Chatham' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .bundle 2 | debug.log 3 | doc/rdoc 4 | activeresource/doc 5 | activerecord/doc 6 | actionpack/doc 7 | actionmailer/doc 8 | activesupport/doc 9 | railties/test/500.html 10 | railties/doc/guides/html/images 11 | railties/doc/guides/html/stylesheets 12 | railties/guides/output 13 | .idea 14 | pkg/*.gem 15 | /tmp 16 | -------------------------------------------------------------------------------- /activerecord/test/models/topic_kwarg_scopes.rb: -------------------------------------------------------------------------------- 1 | class Topic 2 | named_scope :written, lambda { |before:| 3 | if before 4 | { :conditions => ['written_on < ?', before] } 5 | end 6 | } 7 | 8 | def self.for_author(author_name:) 9 | scoped conditions: { author_name: author_name } 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /activerecord/test/cases/connection_test_firebird.rb: -------------------------------------------------------------------------------- 1 | require "cases/helper" 2 | 3 | class FirebirdConnectionTest < ActiveRecord::TestCase 4 | def test_charset_properly_set 5 | fb_conn = ActiveRecord::Base.connection.instance_variable_get(:@connection) 6 | assert_equal 'UTF8', fb_conn.database.character_set 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/integration_test/templates/integration_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | 3 | class <%= class_name %>Test < ActionController::IntegrationTest 4 | fixtures :all 5 | 6 | # Replace this with your real tests. 7 | test "the truth" do 8 | assert true 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/performance_test/templates/performance_test.rb: -------------------------------------------------------------------------------- 1 | require 'test_helper' 2 | require 'performance_test_help' 3 | 4 | class <%= class_name %>Test < ActionController::PerformanceTest 5 | # Replace this with your real tests. 6 | def test_homepage 7 | get '/' 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /activerecord/test/fixtures/references.yml: -------------------------------------------------------------------------------- 1 | michael_magician: 2 | id: 1 3 | person_id: 1 4 | job_id: 3 5 | favourite: false 6 | 7 | michael_unicyclist: 8 | id: 2 9 | person_id: 1 10 | job_id: 1 11 | favourite: true 12 | 13 | david_unicyclist: 14 | id: 3 15 | person_id: 2 16 | job_id: 1 17 | favourite: false 18 | -------------------------------------------------------------------------------- /activerecord/test/migrations/broken/100_migration_that_raises_exception.rb: -------------------------------------------------------------------------------- 1 | class MigrationThatRaisesException < ActiveRecord::Migration 2 | def self.up 3 | add_column "people", "last_name", :string 4 | raise 'Something broke' 5 | end 6 | 7 | def self.down 8 | remove_column "people", "last_name" 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /activerecord/test/migrations/valid/2_we_need_reminders.rb: -------------------------------------------------------------------------------- 1 | class WeNeedReminders < ActiveRecord::Migration 2 | def self.up 3 | create_table("reminders") do |t| 4 | t.column :content, :text 5 | t.column :remind_at, :datetime 6 | end 7 | end 8 | 9 | def self.down 10 | drop_table "reminders" 11 | end 12 | end -------------------------------------------------------------------------------- /railties/lib/rails_generator/generators/components/plugin/templates/README: -------------------------------------------------------------------------------- 1 | <%= class_name %> 2 | <%= "=" * class_name.size %> 3 | 4 | Introduction goes here. 5 | 6 | 7 | Example 8 | ======= 9 | 10 | Example goes here. 11 | 12 | 13 | Copyright (c) <%= Date.today.year %> [name of plugin creator], released under the MIT license 14 | -------------------------------------------------------------------------------- /railties/lib/rails_generator/scripts/update.rb: -------------------------------------------------------------------------------- 1 | require File.dirname(__FILE__) + '/../scripts' 2 | 3 | module Rails::Generator::Scripts 4 | class Update < Base 5 | mandatory_options :command => :update 6 | 7 | protected 8 | def banner 9 | "Usage: #{$0} [options] scaffold" 10 | end 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /activerecord/test/migrations/duplicate/2_we_need_reminders.rb: -------------------------------------------------------------------------------- 1 | class WeNeedReminders < ActiveRecord::Migration 2 | def self.up 3 | create_table("reminders") do |t| 4 | t.column :content, :text 5 | t.column :remind_at, :datetime 6 | end 7 | end 8 | 9 | def self.down 10 | drop_table "reminders" 11 | end 12 | end -------------------------------------------------------------------------------- /activerecord/test/migrations/missing/3_we_need_reminders.rb: -------------------------------------------------------------------------------- 1 | class WeNeedReminders < ActiveRecord::Migration 2 | def self.up 3 | create_table("reminders") do |t| 4 | t.column :content, :text 5 | t.column :remind_at, :datetime 6 | end 7 | end 8 | 9 | def self.down 10 | drop_table "reminders" 11 | end 12 | end -------------------------------------------------------------------------------- /activesupport/lib/active_support/all.rb: -------------------------------------------------------------------------------- 1 | # For forward compatibility with Rails 3. 2 | # 3 | # require 'active_support' loads a very bare minumum in Rails 3. 4 | # require 'active_support/all' loads the whole suite like Rails 2 did. 5 | # 6 | # To prepare for Rails 3, switch to require 'active_support/all' now. 7 | 8 | require 'active_support' 9 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/core_ext/class.rb: -------------------------------------------------------------------------------- 1 | require 'active_support/core_ext/class/attribute_accessors' 2 | require 'active_support/core_ext/class/inheritable_attributes' 3 | require 'active_support/core_ext/class/removal' 4 | require 'active_support/core_ext/class/delegating_attributes' 5 | require 'active_support/core_ext/class/attribute' 6 | -------------------------------------------------------------------------------- /activesupport/lib/active_support/json/encoders/object.rb: -------------------------------------------------------------------------------- 1 | class Object 2 | # Dumps object in JSON (JavaScript Object Notation). See www.json.org for more info. 3 | def to_json(options = nil) 4 | ActiveSupport::JSON.encode(as_json(options)) 5 | end 6 | 7 | def as_json(options = nil) 8 | instance_values 9 | end 10 | end 11 | --------------------------------------------------------------------------------