Sha256: 094ab55c58376acce1f1c1f983e5ee312eceece685ab82e7a1bcdc39791afba9
Contents?: true
Size: 818 Bytes
Versions: 1
Compression:
Stored size: 818 Bytes
Contents
namespace :db do namespace :redis do desc "Reset active Redis databases" task :reset do puts "== Reset: reseting active ".ljust(80, "=") total_task_start_time = Time.current ActiveOrm::Redis::Connection.flush total_task_elapsed_time = (Time.current - total_task_start_time).round(5) puts "== Reset: reset active (#{total_task_elapsed_time}s) ".ljust(80, "=") puts "" end desc "Reset all Redis databases" task :reset_all do puts "== Reset: reseting all ".ljust(80, "=") total_task_start_time = Time.current ActiveOrm::Redis::Connection.flush_all total_task_elapsed_time = (Time.current - total_task_start_time).round(5) puts "== Reset: reset all (#{total_task_elapsed_time}s) ".ljust(80, "=") puts "" end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
active_orm-2.0.2 | lib/tasks/redis.rake |