Permalink
Browse files

changed no_migrations option to skip-migrations and fixed errant crea…

…tion of sessions directory
  • Loading branch information...
1 parent 29f7e4e commit 714e72e7a61c1457a3c09abcfbf1b7cf647f4c4b @stonean stonean committed Jul 18, 2008
Showing with 7 additions and 5 deletions.
  1. +3 −0 History.txt
  2. +4 −5 rails_generators/lockdown/lockdown_generator.rb
View
@@ -1,3 +1,6 @@
+== 0.5.14 2008-07-xx
+* Change: option no_migration to skip-migrations to mimick other generator options
+
== 0.5.13 2008-07-10
* Add: Support for --namespace option on generator. Use as ./script generate lockdown --all --namespace=admin
@@ -83,7 +83,6 @@ def add_management
end
def add_login
- @m.directory "app/controllers/sessions"
@m.directory "app/views/sessions"
@m.template "app/controllers/sessions_controller.rb",
@@ -104,7 +103,7 @@ def add_models
write_model("user_group")
write_model("profile")
- unless options[:no_migrations]
+ unless options[:skip_migrations]
write_migration("create_profiles")
write_migration("create_users")
write_migration("create_user_groups")
@@ -190,13 +189,13 @@ def add_options!(opt)
opt.on("--namespace namespace",
"Install lockdown templates with a namespace") { |v| options[:namespace] = v }
opt.on("--models",
- "Install only models and migrations (skip migrations by --no_migrations).") { |v| options[:models] = v }
+ "Install only models and migrations (skip migrations by --skip-migrations).") { |v| options[:models] = v }
opt.on("--management",
"Install management functionality. Which is --all minus --login. All models (migrations) included. ") { |v| options[:management] = v }
opt.on("--login",
"Install login functionality. Which is --all minus --management. All models (migrations) included. ") { |v| options[:login] = v }
- opt.on("--no_migrations",
- "Skip migrations installation") { |v| options[:no_migrations] = v }
+ opt.on("--skip-migrations",
+ "Skip migrations installation") { |v| options[:skip_migrations] = v }
end
def write_migration(str)

0 comments on commit 714e72e

Please sign in to comment.