mirror of
https://github.com/ryankazokas/turbovault-app.git
synced 2026-04-16 21:02:52 +00:00
21 lines
672 B
Ruby
21 lines
672 B
Ruby
class SeedGenres < ActiveRecord::Migration[8.1]
|
|
def change
|
|
# Create Genres
|
|
puts "Creating genres..."
|
|
genres = [
|
|
"Action", "Adventure", "RPG", "JRPG", "Strategy", "Simulation",
|
|
"Platformer", "Fighting", "Racing", "Sports", "Puzzle", "Horror",
|
|
"Stealth", "Shooter", "FPS", "TPS", "Rhythm", "Visual Novel",
|
|
"Roguelike", "Metroidvania", "Sandbox", "MMO", "Turn-Based",
|
|
"Real-Time Strategy", "Tower Defense", "Card Game", "Party Game",
|
|
"Educational", "Survival", "Battle Royale"
|
|
]
|
|
|
|
genres.each do |genre_name|
|
|
Genre.find_or_create_by!(name: genre_name)
|
|
end
|
|
|
|
puts "Created #{Genre.count} genres"
|
|
end
|
|
end
|