namespace :wittle do desc "Generate new puzzles for the day" task :generate_puzzles => :environment do require "wittle_generator" Puzzle.create(data: WittleGenerator.new.generate_easy, category: :normal) Puzzle.create(data: WittleGenerator.new.generate_medium, category: :hard) Puzzle.create(data: WittleGenerator.new.generate_expert, category: :expert) end end