Class: Jets::Commands::Db::Tasks::Seeder
- Inherits:
-
Object
- Object
- Jets::Commands::Db::Tasks::Seeder
- Defined in:
- lib/jets/commands/db/tasks.rb
Overview
Instance Method Summary collapse
-
#initialize(seed_file) ⇒ Seeder
constructor
A new instance of Seeder.
- #load_seed ⇒ Object
Constructor Details
#initialize(seed_file) ⇒ Seeder
Returns a new instance of Seeder.
35 36 37 |
# File 'lib/jets/commands/db/tasks.rb', line 35 def initialize(seed_file) @seed_file = seed_file end |
Instance Method Details
#load_seed ⇒ Object
39 40 41 42 |
# File 'lib/jets/commands/db/tasks.rb', line 39 def load_seed raise "Seed file '#{@seed_file}' does not exist" unless File.file?(@seed_file) load @seed_file end |