diff options
author | Star Rauchenberger <fefferburbia@gmail.com> | 2023-11-30 13:29:08 -0500 |
---|---|---|
committer | Star Rauchenberger <fefferburbia@gmail.com> | 2023-11-30 13:29:08 -0500 |
commit | 0929719a845897cc8567cf972e07a69a71f0fa6f (patch) | |
tree | 2b6f69c1d906abb6e0abf8a0f1d51725bc78087d /lib/tasks | |
parent | 01c1947537e4e23ded0c16812a7cd9d49ad88356 (diff) | |
download | wittle-0929719a845897cc8567cf972e07a69a71f0fa6f.tar.gz wittle-0929719a845897cc8567cf972e07a69a71f0fa6f.tar.bz2 wittle-0929719a845897cc8567cf972e07a69a71f0fa6f.zip |
Migrate to a full rails app
Diffstat (limited to 'lib/tasks')
-rw-r--r-- | lib/tasks/.keep | 0 | ||||
-rw-r--r-- | lib/tasks/wittle_tasks.rake | 8 |
2 files changed, 5 insertions, 3 deletions
diff --git a/lib/tasks/.keep b/lib/tasks/.keep new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/lib/tasks/.keep | |||
diff --git a/lib/tasks/wittle_tasks.rake b/lib/tasks/wittle_tasks.rake index b9300c7..1be45e2 100644 --- a/lib/tasks/wittle_tasks.rake +++ b/lib/tasks/wittle_tasks.rake | |||
@@ -1,8 +1,10 @@ | |||
1 | namespace :wittle do | 1 | namespace :wittle do |
2 | desc "Generate new puzzles for the day" | 2 | desc "Generate new puzzles for the day" |
3 | task :generate_puzzles => :environment do | 3 | task :generate_puzzles => :environment do |
4 | Wittle::Puzzle.create(data: WittleGenerator.new.generate_easy, category: :normal) | 4 | require "wittle_generator" |
5 | Wittle::Puzzle.create(data: WittleGenerator.new.generate_medium, category: :hard) | 5 | |
6 | Wittle::Puzzle.create(data: WittleGenerator.new.generate_expert, category: :expert) | 6 | Puzzle.create(data: WittleGenerator.new.generate_easy, category: :normal) |
7 | Puzzle.create(data: WittleGenerator.new.generate_medium, category: :hard) | ||
8 | Puzzle.create(data: WittleGenerator.new.generate_expert, category: :expert) | ||
7 | end | 9 | end |
8 | end | 10 | end |