Commit Graph

1814 Commits

Author SHA1 Message Date
Jeremy Kemper
3ce6a10b67 Contortions to work around brittle naming dependency 2009-11-09 20:10:10 -08:00
José Valim
51fe6d05e7 Refactor generators a little bit.
Signed-off-by: Yehuda Katz <wycats@mobile-166-129-219-135.mycingular.net>
2009-11-08 18:41:44 -08:00
José Valim
216e8c6bfa Update Rails Generators to use Thor 0.12.0.
Signed-off-by: Yehuda Katz <wycats@mobile-166-129-219-135.mycingular.net>
2009-11-08 18:41:44 -08:00
Jeremy Kemper
cb9a1759c0 Fix generators tests that expect a class name 2009-11-05 16:12:02 -08:00
Yehuda Katz
b0dfd1d19b Update Ruby version check to 1.8.7 2009-11-05 15:38:25 -08:00
Yehuda Katz + Carl Lerche
4369426993 Add the ability to merge initializers from various objects in order. 2009-11-05 14:45:53 -08:00
Yehuda Katz + Carl Lerche
897164ddb7 Conceptually unify instance & global initializers 2009-11-05 14:44:29 -08:00
Jeremy Kemper
a3d5274e67 Configure generator when needed rather than during initialization 2009-11-03 18:58:40 -08:00
José Valim
d627c932bd Pass config.generators options along when RAILS_GENERATORS is set and show --force-plural message just once.
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-11-03 18:22:05 -08:00
Jeremy Kemper
e5211e3bd0 Improve Gemfile commentary 2009-11-03 16:36:19 -08:00
José Valim
3b8e29fe56 Remove --freeze (since Rails will come bundled in all new apps) and update gem action to change Gemfile instead of config.environment.
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-11-03 16:32:47 -08:00
José Valim
3fb548cac3 Ensure ActiveRecord is loaded on revoke/destroy.
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-11-03 16:32:47 -08:00
José Valim
e15b5eda2b Avoid duplicated names on help description and show proper error message if trying to load a Rails 2.x generator.
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-11-03 16:32:47 -08:00
José Valim
d226f17507 Ensure that generators can be invoked from any directory.
Signed-off-by: Engine Yard <engineyard@Engine-Yards-MacBook-Pro.local>
2009-11-02 18:20:16 -08:00
Jeremy Kemper
36a9644b86 Clarify date/time dependencies 2009-11-02 17:50:12 -08:00
Yehuda Katz
14370e1aab CI breakage
This reverts commit a288b74f1c75c6f100de7611a5093a421f1ad6d1.
2009-11-02 17:12:01 -08:00
José Valim
a288b74f1c Generators should use Rails.root instead of Dir.pwd [#3408 status:resolved]
Signed-off-by: Yehuda Katz <wycats@gmail.com>
2009-10-28 16:54:38 -04:00
Yehuda Katz
86596975be Tests pass again 2009-10-27 19:05:47 -07:00
Yehuda Katz + Carl Lerche
df95f16570 Update initializable 2009-10-27 17:01:33 -07:00
Yehuda Katz + Carl Lerche
da62a7c536 Duplicate AS code no longer needed 2009-10-27 17:01:33 -07:00
José Valim
c28a45ad8b Fix rake dev and update vendored Thor.
Signed-off-by: Yehuda Katz <wycats@gmail.com>
2009-10-27 16:46:19 -07:00
Joshua Peek
a840c8afbf Restore rake routes [#3402 state:resolved] 2009-10-24 18:08:54 -05:00
Joshua Peek
fa1926ddaa Exclude gem backtrace filter if rubygems is not loaded 2009-10-20 09:32:26 -05:00
Jeremy Kemper
248d84f2e6 Simplify path expansions 2009-10-19 21:00:22 -07:00
Jeremy Kemper
acb1624f27 Merge commit 'josevalim/fixes'
Conflicts:
	railties/test/generators/app_generator_test.rb
2009-10-19 18:37:19 -07:00
Jeremy Kemper
7ab30599a6 Error message references application.rb instead of environment.rb 2009-10-19 18:33:57 -07:00
Jeremy Kemper
4afe70790c Check for environment.rb 2009-10-19 18:12:29 -07:00
Jeremy Kemper
3072bf7555 Check for bundler environment or 2.x-style vendor/rails + rubygems 2009-10-19 18:10:14 -07:00
Pratik Naik
1ac5cf4788 Make sure boot.rb requires rubygems only when needed 2009-10-19 15:06:54 -02:00
Carl Lerche
d0f4d93df8 Remove some remnants of config.gem 2009-10-17 14:38:40 -07:00
José Valim
1f9d234a6b By default use ActiveModel API in controller generators, unless otherwise specified [#3123 status:resolved] 2009-10-17 15:56:44 -03:00
José Valim
03c5a0e5c4 Make app generatoor specs green once again. 2009-10-17 15:54:58 -03:00
Joshua Peek
e13d232150 Add stub for configuring your package manager 2009-10-16 20:57:46 -05:00
Carl Lerche
e1fdc8bba3 Remove config.gem in favor of using the bundler. This makes config/boot.rb obsolete.
The bundler library is at: http://github.com/wycats/bundler/ and is a rubygem.
2009-10-16 18:10:52 -07:00
Joshua Peek
29ba9c0307 Use Rails.root in statistics rake task 2009-10-16 19:40:59 -05:00
Joshua Peek
7593e8b8b5 Rakefile doesn't need initializers to be ran 2009-10-16 19:40:08 -05:00
Joshua Peek
c7bf1058d3 Fix incorrect path in script/runner template 2009-10-16 19:33:25 -05:00
Joshua Peek
f1640a1653 script/runner should require environment 2009-10-16 19:33:25 -05:00
Joshua Peek
8f2d8f4528 script/performance/profiler should require environment 2009-10-16 19:33:24 -05:00
Joshua Peek
2f7217c76a script/performance/benchmarker should require environment 2009-10-16 19:33:24 -05:00
Joshua Peek
7635c9f4c0 script/generate should require environment 2009-10-16 19:33:24 -05:00
Joshua Peek
c40f79f330 script/about should require environment 2009-10-16 19:24:19 -05:00
Joshua Peek
c1261b5484 Use Rails.application where we want a valid rack app 2009-10-16 19:04:28 -05:00
Joshua Peek
d859402696 Use Rails.initialize! where we just want to run the initializers and aren't concerned about the config 2009-10-16 18:58:35 -05:00
Joshua Peek
92bfc693f2 Rackup file should require environment 2009-10-16 18:46:34 -05:00
Carl Lerche
591eaf3b2c Get apps generated with working again. 2009-10-16 16:03:14 -07:00
Joshua Peek
2ca93403a2 Ruby 1.9: qualify toplevel File reference since config.ru could be eval'd in a different scope
Restores accidentally-reverted commit.
2009-10-16 14:21:27 -07:00
Carl Lerche
2110a524a4 Deprecate RAILS_ROOT in favor of Rails.root (which proxies to the application's object root) 2009-10-16 12:51:02 -07:00
Jeremy Kemper
71f7e75d95 Merge branch 'master' into orchestra 2009-10-15 17:36:54 -07:00
Carl Lerche
97296b11e2 Have config/application.rb contain the application definition and require that file instead of config/boot.rb or config/environment.rb in script/*. 2009-10-15 14:54:12 -07:00
José Valim
2d7abe245e Renamed Orchestra to Notifications once again [#3321 state:resolved] 2009-10-15 18:51:51 -03:00
José Valim
aeaabc6d2d Configure Orchestra on initialization. 2009-10-15 18:19:25 -03:00
Carl Lerche
bf9819f73d Have Rails.root be based off of config.ru 2009-10-14 16:40:25 -07:00
Carl Lerche
ff8be66f24 Finish porting over the initializers to the app object and fix all the tests 2009-10-14 11:47:37 -07:00
Yehuda Katz + Carl Lerche
5ffb877d3a Add Gemfile to the rails application generator 2009-10-14 11:18:45 -07:00
Yehuda Katz + Carl Lerche
d56984c016 Make rails configuration's path object's root lazy 2009-10-14 11:18:45 -07:00
Jeremy Kemper
7b8f9d254a Fix generators load paths 2009-10-11 12:35:01 -07:00
Carl Lerche
992c2db76c Finish porting over the initializers to the app object and fix all the tests 2009-10-08 18:12:28 -07:00
Carl Lerche
5c42157cd8 Even more initializers ported over 2009-10-08 15:30:17 -07:00
Carl Lerche
ed77e84c4b Ported over more initializers 2009-10-08 15:08:08 -07:00
Carl Lerche
feb04bf897 Move the ensure_tmp_directories_exist initializer to the application object 2009-10-08 12:31:09 -07:00
Carl Lerche
e4d7e5090c Moving more initializers into the application object 2009-10-08 12:31:09 -07:00
Carl Lerche
6d6ae0841c Start moving the initializers into the application object 2009-10-08 12:31:09 -07:00
Carl Lerche
d096589245 Remove the old initializer file. 2009-10-08 12:31:09 -07:00
Michael Koziarski
28bd0873ff Don't need h in there now that XSS protection is on by default 2009-10-08 14:34:15 +13:00
Joshua Peek
b480da5cd6 Coerce all out going body parts to Strings 2009-10-05 13:58:43 -05:00
Joshua Peek
570f055c44 Yank FCGI Handler from core
http://github.com/rails/fcgi_handler
2009-10-05 11:16:24 -05:00
Joshua Peek
20d6938453 Rewrite FCGI handler test 2009-10-05 10:36:05 -05:00
Carl Lerche
2370e87ae0 Remove all calls to Rails::Initializer from boot.rb
This is starting a refactor of the rails initialization process. The boot.rb file will not remain the same.
2009-09-30 12:05:34 -07:00
Carl Lerche
34aae6d739 Remove a duplicate initializer 2009-09-29 17:46:33 -07:00
Carl Lerche
c9d4529c9d Change Rails::Application to a class that is inherited from.
This is still very experimental.
2009-09-29 17:33:17 -07:00
Carl Lerche
6b086449be Fix the broken railties isolation tests 2009-09-29 16:07:29 -07:00
Yehuda Katz + Carl Lerche
6f6a589d4b Create the application object from config/environment.rb
This is preliminary and not necessarily reflective of the
  full plan.
2009-09-28 18:00:26 -07:00
Joshua Peek
a6757a02e1 Move middleware and route configuration from AC::Dispatcher to Rails application object 2009-09-26 21:59:28 -05:00
Joshua Peek
b0506b086f Create separate middleware stack for initializer 2009-09-26 21:07:49 -05:00
Joshua Peek
acfeec5151 Allow integration test rack app to be set with "@app" ivar instead of using open_session 2009-09-26 20:51:05 -05:00
Joshua Peek
1f72700575 Move default middleware stack into initializer 2009-09-26 13:41:32 -05:00
Joshua Peek
db65bb5a31 Pull middleware for Rails info from the initializer instead of ActionController 2009-09-26 12:41:17 -05:00
Joshua Peek
15cffe6fbc ruby 1.9: Qualify toplevel File reference since config.ru could be eval'd in a different scope 2009-09-26 11:52:37 -05:00
Joshua Peek
ef58194129 Move Rails::Static into ActionDispatch 2009-09-26 11:37:42 -05:00
Joshua Peek
dbb32115ef Enable static asset server by default 2009-09-26 11:24:56 -05:00
Joshua Peek
79a4d505fa Add gem filter for default gem path since it maybe different than the set of gem paths 2009-09-26 11:04:08 -05:00
Joshua Peek
5eeed9f00a Move tmp directory creation from server to initializer 2009-09-26 10:56:36 -05:00
Joshua Peek
c83c0f6936 Remove config.ru generation from --with-dispatchers option 2009-09-25 23:15:49 -05:00
Joshua Peek
5fba5409f7 Fix railties tests 2009-09-25 22:54:41 -05:00
Joshua Peek
85e0a6cd7d Set const for application object. "Basecamp::Application" 2009-09-25 22:35:54 -05:00
Joshua Peek
968c994c3b Initializer.run returns an application object 2009-09-25 22:28:09 -05:00
Joshua Peek
dfbd3b9409 Extract "parse_config" into AD 2009-09-25 21:40:55 -05:00
Joshua Peek
accd9b4634 Restore "Start Rails::Application object
This reverts commit f14ad4145622f45e9bf7433b5fdef4ce427efe4b.
2009-09-25 21:32:28 -05:00
Joshua Peek
bace497aea Remove relative url configuration from script/server 2009-09-25 21:17:38 -05:00
Joshua Peek
382870f763 Generate a config.ru stub 2009-09-25 21:10:00 -05:00
Joshua Peek
f14ad41456 Revert "Start Rails::Application object"
This reverts commit 4129449594ad3d8ff2f8fb4836104f25406a104f.
2009-09-25 20:41:40 -05:00
Yehuda Katz + Carl Lerche
4129449594 Start Rails::Application object 2009-09-25 17:42:53 -07:00
Yehuda Katz + Carl Lerche
f0dd77c6be Move railties/lib/* into railties/lib/* 2009-09-24 16:11:41 -07:00
Joshua Peek
c2f8b4e92f Remove dead requries to AC integration. Rely on autoloads instead 2009-09-24 09:41:46 -05:00
Mike Gunderloy
3600c3840e More places to bump rack-test version [#3250 state:resolved]
Signed-off-by: Joshua Peek <josh@joshpeek.com>
2009-09-23 09:21:44 -05:00
Jeremy Kemper
70d2640700 Cherry-pick core extensions. Don't explicitly require rubygems. Use load path for vendored thor. 2009-09-14 13:04:43 -07:00
Akira Matsuda
3ce16b4c5f Ruby 1.9 compat: Avoid using the return value of FileUtils.mkdir_p, as it does not return a String but an Array in Ruby 1.9
[#2018 state:committed milestone:2.3.5]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-09-11 19:20:57 -07:00
Joshua Peek
72721c6725 Add gem load paths after loading environment 2009-09-11 10:31:31 -05:00
Carl Lerche
f416f9f0ae Vendor the latest version of the bundler 2009-09-03 09:31:04 -07:00
Yehuda Katz
847907d753 Make Sam Ruby's test suite happy 2009-09-01 19:37:49 -07:00
Joshua Peek
14870257c1 Initializer middleware helper needs to require actioncontroller 2009-08-31 21:09:39 -05:00
Yehuda Katz
7e3abbfdc2 Merge commit 'jose/generators' 2009-08-31 11:07:37 -07:00
Jay Pignata
57f7308da4 Changing plugin loader to use blocks instead of Symbol#to_proc to ensure tests run without activesupport
[#3118 state:committed]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-08-30 17:01:59 -07:00
Antonio Tapiador del Dujo
cf4846c6ae I18n support for plugins
Rails will now automatically add locale files found in any engine's locale
directory to the I18n.load_path (i.e. files that match the glob pattern
"config/locales/**/*.{rb,yml}" relative to engine directories).

[#2325 state:committed]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-08-30 13:36:22 -07:00
José Valim
d8d83e7821 Change div.attribute to div.field and add some _form to tests. 2009-08-30 18:49:54 +02:00
José Valim
0efedf2a30 Ensure scaffold works properly even if plural name is given. [#3062] 2009-08-30 17:58:20 +02:00
José Valim
5096ba961c Remove inline css. [#593 status:resolved] 2009-08-30 17:04:16 +02:00
José Valim
5d645c271b Change scaffold to use _form as partial and div's instead of paragraphs. [#1760 status:resolved] 2009-08-30 16:53:23 +02:00
David Calavera
0fc5c59b37 Rails templates git command runs inside another directory [#2466 status:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
2009-08-30 16:25:07 +02:00
Rodrigo Rosenfeld Rosas
0f9675a872 Fix spelling in Rails 'generator' generator. [#3080 status:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
2009-08-30 16:18:21 +02:00
José Valim
72c6ea1022 Update vendored thor. 2009-08-30 16:16:53 +02:00
Jeremy Kemper
f6ca7e4e75 Prefer utf8_unicode_ci (better) over utf8_general_ci (faster) 2009-08-27 23:07:43 -07:00
Pratik Naik
25e5b0c4a8 Remove support for SQLite 2.
If you're still using it, please install the plugin from git://github.com/rails/sqlite2_adapter.git
2009-08-17 14:54:34 +01:00
José Valim
5f7cfffc53 Use less strict rules in generators lookup, so people can lay their generators wherever they want. 2009-08-10 18:29:20 +02:00
Kamal Fariz Mahyuddin
600a89f208 find_cmd should return the full path of the db command
[#1488 state:committed]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-08-10 00:04:37 -07:00
Joshua Nichols
84d24cdae8 Only load db/schema.rb if it exists; otherwise, display a message to run db:migrate or remove active_record in environment.rb.
[#3012 state:committed]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-08-09 20:18:56 -07:00
jastix
a1c289dbe4 Require test/unit in the generated test_helper for plugin [#1878 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-08-09 17:56:41 +01:00
José Valim
1ea7a00bc4 Refactored create_migration on model generator.
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-08-09 15:57:59 +01:00
Hugo Peixoto
22b38c18c6 Fixed generating a namespaced model with table pluralization turned off. Add tests for namespaced model generation.
[#767 state:committed]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-08-09 02:38:35 -07:00
Yehuda Katz
60219a13da Add a .tmp path 2009-08-09 05:52:49 -03:00
Pratik Naik
89c8affe47 Use Pathname for checking if sqlite path is absolute 2009-08-09 01:54:08 +01:00
bastilian
071f48b716 Make sure db:drop doesn't fail when sqlite db is given by an absolute path [#1789 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-08-09 01:54:08 +01:00
Michael Koziarski
df745ed805 Depend on rubygems 1.3.2
Also move the min_version definition up a line so it's present in the rescue block down below.
2009-08-09 11:11:34 +12:00
Matt Duncan
bee3e099bd Users can now pass :branch for git plugins and :revision for subversion plugins
[#2352 status:resolved]

Signed-off-by: José Valim <jose.valim@gmail.com>
2009-08-08 23:42:18 +01:00
José Valim
3ea091e1cc Improved coverage for session_migration generator. [#3008 status:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-08-08 23:42:18 +01:00
Elad Meidar
c0f828ca4f Fixed reference to AR::SessionStore::Session.table_name in session migrations
Signed-off-by: José Valim <jose.valim@gmail.com>
2009-08-08 23:42:18 +01:00
Pratik Naik
ed8a0a1c23 Ensure db:drop:all doesn't error out on exception [#2997 state:resolved] [Anthony Caliendo] 2009-08-08 17:53:51 +01:00
Cristi Balan
7f84f14efa Add rake db:forward - opposite of db:rollback [#768 state:resolved]
Example:
  rake db:forward # performs the next migration
  rake db:forward STEP=4 # performs the next 4 migrations

Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-08-08 17:41:43 +01:00
José Valim
016ed9b429 Added rubygems to generators load_paths, but we only load generators from gems that are alraedy activated. This fixes the version problem and avoid silly conflicts. 2009-08-08 17:48:07 +02:00
José Valim
469d89dd44 Rename Rails::Generators::ActionORM to Rails::Generators::ActiveModel. 2009-08-08 17:48:07 +02:00
Mike Breen
e8dc151396 Add option to routes task to target a specific controller with CONTROLLER=x.
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#2928 state:committed]
2009-08-08 14:38:33 +12:00
José Valim
55575e2165 Allow rails templates relative to the current path to be given. 2009-08-07 17:17:51 +02:00
José Valim
c44f7e39f4 Updated vendored thor to 0.11.5 2009-08-07 17:16:15 +02:00
James Tucker
b7052b8dc3 Dont require thin as the thin rack adapter is now upstream
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-08-05 23:00:33 +01:00
Yehuda Katz
2c2ca833a5 Removed default_internal, which was preventing round-tripping of some encodings. 2009-07-30 09:55:17 -07:00
Pratik Naik
83537bf090 Generator config should be commented by default 2009-07-30 17:49:48 +01:00
Pratik Naik
61d995f7ed Remove whitespaces from the default mailer file 2009-07-30 17:49:48 +01:00
José Valim
7d56fd9f08 Always use application generator to run templates. 2009-07-28 16:21:30 +02:00
José Valim
d9aae2b56e Merge branch 'master' of git://github.com/rails/rails 2009-07-28 09:00:33 +02:00
José Valim
419ca7a747 Ensure that developers options are overwritten by user options. 2009-07-28 08:48:21 +02:00
José Valim
67c2f53938 Allow templates for non namespaced generators too. 2009-07-25 21:14:43 +02:00
José Valim
edd07b5a7a Updated vendored thor to 0.11.3. 2009-07-23 14:30:49 +02:00
José Valim
178044dbd2 Do not try to use thor gem. 2009-07-23 07:33:54 +02:00
John Duff
0c68d23f19 make pass through error code configurable [#2817 state:resolved]
Signed-off-by: Joshua Peek <josh@joshpeek.com>
2009-07-22 22:21:06 -05:00
José Valim
33048b6e27 Solving merge conflicts. 2009-07-21 12:51:53 +02:00
José Valim
edda0bfe76 Allow nested and multiple fallbacks for generators. 2009-07-21 12:16:25 +02:00
José Valim
10fd021789 Change attributes default type to array to allow order to be preserved. 2009-07-21 12:00:02 +02:00
José Valim
c90419d4f4 Update db:sessions:create to use the proper generator. 2009-07-21 11:28:54 +02:00
Yehuda Katz + Carl Lerche
e7a2496fda Vendor the bundler project 2009-07-20 18:03:38 -07:00
José Valim
d6a590a710 Modified rake tasks to use new app generator structure and updated Thor version. 2009-07-16 11:17:19 +02:00
José Valim
b03034a686 Update vendored Thor to have latest actions updates. 2009-07-16 10:16:23 +02:00
José Valim
e3d5364e41 Implemented generaators fallbacks. 2009-07-16 00:17:28 +02:00
José Valim
9c4ba74b7c Change generators configuration to have a hash style. 2009-07-15 23:38:41 +02:00
José Valim
bcf754d8c4 Add a form hook to erb scaffold. Customize and go! 2009-07-15 22:43:25 +02:00
José Valim
8d47078a49 Added source_paths to rails generators. If a template is added to RAILS_ROOT/lib/templates/base/generator it will be used. For example, to customize edit.html.erb template on scaffold, just add a customized copy at RAILS_ROOT/lib/templates/erb/scaffold. 2009-07-15 22:37:22 +02:00
José Valim
b4ef958de6 Change false to :verbose => false as in new Thor version. 2009-07-15 20:16:37 +02:00
José Valim
baa4781ac7 Allow nil and false to be given as configuration values and avoid creating unecessary hashes. 2009-07-15 16:53:54 +02:00
José Valim
7022b58842 Allow namespaced configuration on generators. 2009-07-15 16:20:48 +02:00
José Valim
0702e04e0d Refactored some generators to make use of improved invocations on thor. 2009-07-15 11:33:36 +02:00
José Valim
a06c825b46 Updated vendored Thor to 0.11.1 and update Rails::Generators. 2009-07-14 22:20:43 +02:00
José Valim
e96af1eaa2 Add version to thor frozen gem. 2009-07-14 15:44:14 +02:00
José Valim
925c9104e0 Copy Thor files instead of using as a submodule. 2009-07-13 23:21:47 +02:00
José Valim
5021dc69a4 Vendorized Thor. 2009-07-13 23:13:48 +02:00
José Valim
52673cd2ee Added a generator generator. 2009-07-13 23:01:12 +02:00
José Valim
a5ab030ae4 Ensure non timestamped migrations are generated properly. 2009-07-13 22:26:58 +02:00
José Valim
25647f7021 Add some attribute readers to migration module. 2009-07-13 20:42:25 +02:00
José Valim
b9f4ea7198 Add hooks for integration and performance tests. 2009-07-13 18:29:40 +02:00
José Valim
f68e7a3987 Remove generator environment until we have a gem manifest. 2009-07-13 18:18:08 +02:00
José Valim
21019304f0 Make explicit that references and belongs_to types have nil as default value. 2009-07-13 16:18:56 +02:00
José Valim
ae7a7852d5 Always allow params to be skipped on action orm in generators. 2009-07-13 15:08:45 +02:00
José Valim
d5225c1fd5 Do not require options on class_option. 2009-07-13 14:30:32 +02:00
José Valim
cd28dcb5a4 Cache source root in a rails specific variable. 2009-07-13 13:39:48 +02:00
José Valim
3075ae0611 Solving merge conflicts. 2009-07-12 16:29:15 +02:00
Joshua Peek
01d92021e6 Switch scaffolding templates to HTML 5 doctype 2009-07-10 11:34:39 -05:00
José Valim
cca16a015d Do not clean up frameworks on generators environment, otherwise initializers, gems and plugins might not be loaded properly. 2009-07-09 10:04:59 +02:00
José Valim
09c288f0c5 Add the new generators environment and update commands. 2009-07-08 12:55:50 +02:00
José Valim
c9ea21717e Generators are configured on initialization if RAILS_ENV=generators. 2009-07-08 12:53:45 +02:00
José Valim
2699e9c2dd Added config.generators with tests. 2009-07-08 12:53:45 +02:00
José Valim
c07746cbdf Merge branch 'master' of git://github.com/rails/rails 2009-07-08 12:53:13 +02:00
Yehuda Katz + Carl Lerche
61604feec0 Get Initializer tests running without requiring parts of Rails being loaded first 2009-07-06 12:25:34 -07:00
Yehuda Katz + Carl Lerche
9a42e06dd8 Reapply Rails::Application::Path tweaks
Reapplies: a4bdc00fec623f72592e663e6d7830eea0bc6ea4
             3c1dab72259d01c6335bf359d7f9b3af69d45bb4
2009-07-06 10:22:42 -07:00
José Valim
dd7ee082be Use active_support/mini since we just need inflections. 2009-07-06 18:38:27 +02:00
José Valim
66d1b968d1 Make specs pass on Ruby 1.9. 2009-07-06 18:31:28 +02:00
José Valim
eeb6a0786a Load generators from user home and show a error message if they can't be loaded. 2009-07-04 20:17:32 +02:00
José Valim
b277cf28e8 Allow scaffold controller to load action_orm files on demand. 2009-07-04 20:17:32 +02:00
José Valim
35925a8995 Ensure that rails templates methods are invoked with the proper extensions [#2531 status:resolved] 2009-07-04 20:17:32 +02:00
José Valim
8ff214e0db Use the proper shebang when using Ruby 1.9 or jruby or windows. 2009-07-04 20:17:32 +02:00
José Valim
cd388e075c Search for generators on vendorized plugins and gems. 2009-07-04 20:17:31 +02:00
José Valim
37ba0047a9 Removed invoke_if and allow hook_for to accept boolean options. 2009-07-04 20:17:31 +02:00
José Valim
44633dc7a5 Add some tests for no_color! behavior. 2009-07-03 15:12:18 +02:00
José Valim
21db04818e More tests for rails generators and lookup. 2009-07-03 14:57:46 +02:00
José Valim
3ca504c966 Removed remaining old generators files. 2009-07-03 14:57:46 +02:00
José Valim
de68cf7e06 Plugin generators now reflect new generators sutrcture. 2009-07-03 14:57:46 +02:00
José Valim
d1c404ee90 Added lookup to generators. 2009-07-03 14:57:46 +02:00
José Valim
3bf45890b3 Merge branch 'master' of git://github.com/rails/rails 2009-07-03 14:56:19 +02:00
Pratik Naik
a4bdc00fec Revert "Compact the way application paths are defined"
This reverts commit 940aad225af0b963f435a0bf015daece2218d502.

Reason : The server does not start
2009-07-03 12:35:53 +01:00
Pratik Naik
3c1dab7225 Revert "Modify the Rails::Application::Path object to allow for more concise path definition."
This reverts commit 913bb2f4c2feb79dcbc9ed2c0fb1ef6d436f7d02.

Reason : The server does not start
2009-07-03 12:23:57 +01:00
Yehuda Katz + Carl Lerche
378a65a909 Added tests for the :install_gem_spec_stubs initializer 2009-07-02 17:52:46 -07:00
Yehuda Katz + Carl Lerche
940aad225a Compact the way application paths are defined 2009-07-02 15:49:35 -07:00
Yehuda Katz + Carl Lerche
913bb2f4c2 Modify the Rails::Application::Path object to allow for more concise path definition. 2009-07-02 15:47:11 -07:00
J.D. Hollis
9eab435631 Only check for built extensions on gem dependencies that are in vendor/gems. [#2825 state:resolved]
Signed-off-by: Yehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com>
2009-07-02 10:27:54 -07:00
José Valim
b7bc68076c Make color optional. 2009-07-02 15:57:37 +02:00
José Valim
528d555e37 Make invoke output white and use padding. 2009-07-02 15:55:21 +02:00
José Valim
ec55e59e99 Updated commands. 2009-07-02 11:08:07 +02:00
José Valim
776220e1e2 Rename a wrongly named file. 2009-07-02 10:27:40 +02:00
José Valim
ea0b0c820d rm -rf rails_generator/generators 2009-07-02 10:27:40 +02:00
José Valim
c972b25df5 Tests for scaffold generator. 2009-07-02 10:27:40 +02:00
José Valim
a7c1591315 Added stylesheets controller which is invoked by scaffold. 2009-07-02 10:27:40 +02:00
José Valim
7f7afdf0f1 Rename ControllerNamedBase to ScaffoldBase and move ActionORM helpers. 2009-07-02 10:27:40 +02:00
José Valim
1a4d8aca8a Added tests to scaffold controller. 2009-07-02 10:27:40 +02:00
José Valim
86ff074101 Added test unit files for scaffold_controller. 2009-07-02 10:27:40 +02:00
José Valim
80cd16372c Added scaffold views to scaffold controller. 2009-07-02 10:27:39 +02:00
José Valim
9541977e04 Make scaffold controller generate agnostic code and mark some hooks as required. 2009-07-02 10:27:39 +02:00
José Valim
bf672a12a3 Added Rails::Generators::ActionORM to hold ORM methods necessary to build a generator. 2009-07-02 10:27:39 +02:00
José Valim
0760d5b542 Added comments to meta programming code. 2009-07-02 10:27:39 +02:00
José Valim
555a956a66 Ensure both migration and routes are removed on revoke. 2009-07-02 10:27:39 +02:00
José Valim
10a9205c58 Put migration methods into a separate folder and let just ActiveRecord dependency in ActiveRecord models. 2009-07-02 10:27:39 +02:00
José Valim
b77a7dcf4d Added controller named base. 2009-07-02 10:27:39 +02:00
José Valim
d5d0b8ea8e Removing unecessary class methods. 2009-07-02 10:27:39 +02:00
José Valim
35c4df4aa5 Added scaffold_controller. 2009-07-02 10:27:39 +02:00
José Valim
00b168e9d0 Show second level invocations on usage. 2009-07-02 10:27:39 +02:00
José Valim
dec1ee7422 Started with scaffold controller and added remove_hook_for. 2009-07-02 10:27:39 +02:00
José Valim
1c265da1db Merge branch 'master' of git://github.com/rails/rails 2009-07-02 10:25:18 +02:00
Jeremy Kemper
e7312105c7 Merge branch 'master' of git@github.com:rails/rails 2009-07-01 12:55:19 -07:00
Carl Lerche
db3de78a83 Bump up the version to 3.0.pre 2009-06-30 14:37:12 -07:00
Carl Lerche
132e6d0063 Add #concat to Rails::Application::Path 2009-06-30 13:55:11 -07:00
Carl Lerche
9101941c12 Require core_ext/kernel/requires in test_help to providing #require_library_or_gem 2009-06-30 09:05:53 -07:00
Carl Lerche
f66b5d79c1 Stop the initializer from blowing up when builtin_directories is empty 2009-06-30 09:01:46 -07:00
José Valim
4739f0ff5d Small fix to plugin generator. 2009-06-29 21:08:12 +02:00
José Valim
95ef9bd67f Simplifying resource generator. 2009-06-29 19:56:22 +02:00
José Valim
ff4c600448 Added singleton support to resource controller. 2009-06-28 19:57:00 +02:00
José Valim
9413dba432 Added tessts for resources generator. 2009-06-28 19:46:34 +02:00
José Valim
9068bc05b8 Added ResourceGenerator. 2009-06-28 18:28:30 +02:00
José Valim
a2d4d755ae Use inject_into_file instead of gsub_file (the first is reversible) 2009-06-28 16:48:22 +02:00
José Valim
1ca51df000 Added migration and session_migration generator. 2009-06-28 13:16:14 +02:00
José Valim
4f3e44fa03 Move file action only to app generator. 2009-06-28 12:00:13 +02:00
José Valim
496dde95fb Added migrations and make base generators be lazy loaded. 2009-06-28 11:56:44 +02:00
José Valim
c03585aa8d Show invoked generators options on meta generators. 2009-06-27 21:30:00 +02:00
José Valim
fdeee65c96 Add model_subclass generator with deprecation warning. 2009-06-27 21:30:00 +02:00
José Valim
7b6c5ed7db Added parent option to model generator. 2009-06-27 21:30:00 +02:00
José Valim
ff44e5055c Output invocations. 2009-06-27 21:30:00 +02:00
José Valim
1a15dd4de5 Rename invoke_for to hook_for. 2009-06-27 21:30:00 +02:00
José Valim
acaeaf308a Add a fixture replacement hook to TestUnit model generator. 2009-06-27 21:29:59 +02:00
José Valim
8c5622f0d4 Initial scratch of model generators. 2009-06-27 21:29:59 +02:00
José Valim
9acb721e6a Do not generate aliases automatically to avoid conflicts. 2009-06-27 21:29:59 +02:00
José Valim
ff48e23a4e Make Observer generator agnostic. 2009-06-27 21:29:59 +02:00
José Valim
85ff67ce4c Merge branch 'master' of git://github.com/rails/rails 2009-06-27 21:27:21 +02:00
Yehuda Katz + Carl Lerche
188a892c5a Starting to replace scattered path configuration settings with the path object 2009-06-26 17:32:05 -07:00
Yehuda Katz + Carl Lerche
4153c6b720 Finished a first stab at the Rails application path object. 2009-06-26 15:37:52 -07:00