lib/lotus/generators/application/app.rb in lotusrb-0.4.0 vs lib/lotus/generators/application/app.rb in lotusrb-0.4.1

- old
+ new

@@ -108,11 +108,11 @@ gitkeep = '.gitkeep' cli.template(source.join(gitkeep), target.join(dir, gitkeep), opts) end unless git_dir_present? - cli.template(source.join('gitignore.tt'), target.join('.gitignore'), opts) + cli.template(source.join(database_type == :file_system ? 'gitignore.tt' : '.gitignore'), target.join('.gitignore'), opts) cli.run("git init #{Shellwords.escape(target)}", capture: true) end end private @@ -172,11 +172,13 @@ "postgres://localhost/#{app_name}" when 'sqlite', 'sqlite3' "sqlite://db/#{Shellwords.escape(app_name)}" when 'memory' "memory://localhost/#{app_name}" - else + when 'filesystem' "file:///db/#{app_name}" + else + raise "\"#{@database}\" is not a valid database type" end end end end end