Sha256: 4ed1d0f4d37c7d1663738f52915cf1b411586bce47d830c0b7db40599ec54c90

Contents?: true

Size: 513 Bytes

Versions: 10

Compression:

Stored size: 513 Bytes

Contents

module Teleport
  class DatabaseGenerator < Rails::Generators::Base
    source_root File.expand_path("../templates", __FILE__)

    def add
      @name = ask "Type the project's name"
      @username = ask 'Type database username'
      @password = ask 'Type database password'
      template 'database/database.yml', 'config/database.yml'
      template 'database/database.yml', 'config/database.yml.example'
      create_db = ask 'Create database?'
      rake('db:create') if create_db =~ /y/
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
teleporter-2.0.11 lib/generators/teleport/database.rb
teleporter-2.0.10 lib/generators/teleport/database.rb
teleporter-2.0.9 lib/generators/teleport/database.rb
teleporter-2.0.8 lib/generators/teleport/database.rb
teleporter-2.0.7 lib/generators/teleport/database.rb
teleporter-2.0.6 lib/generators/teleport/database.rb
teleporter-2.0.4 lib/generators/teleport/database.rb
teleporter-2.0.2 lib/generators/teleport/database.rb
teleporter-2.0.1 lib/generators/teleport/database.rb
teleporter-2.0.0 lib/generators/teleport/database.rb