Skip to content

Commit

Permalink
use args instead of env variable
Browse files Browse the repository at this point in the history
  • Loading branch information
tapalilov committed Mar 1, 2019
1 parent f2d8ae9 commit 28bbba6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sample/lib/tasks/sample.rake
Expand Up @@ -4,14 +4,14 @@ require 'benchmark'

namespace :db do
desc 'Loads sample data'
task :sample, [:mode] => [:environment] do |t, args|
task :sample, [:mode] => :environment do |t, args|

say "Simple mode: #{@simple_sample_counts.to_json}".yellow
say "Normal mode: #{@normal_sample_counts.to_json}".yellow
say "Full mode: #{@full_sample_counts.to_json}".yellow
say "------------------------------------------------------------------------------------------------".green

mode = ENV['mode'] || args[:mode]
mode = args[:mode]

if mode.nil?
choose do |menu|
Expand Down

0 comments on commit 28bbba6

Please sign in to comment.