summaryrefslogtreecommitdiff
path: root/Rakefile
diff options
context:
space:
mode:
Diffstat (limited to 'Rakefile')
-rw-r--r--Rakefile12
1 files changed, 12 insertions, 0 deletions
diff --git a/Rakefile b/Rakefile
new file mode 100644
index 0000000..d57aeaa
--- /dev/null
+++ b/Rakefile
@@ -0,0 +1,12 @@
+require_relative 'config/initializer.rb'
+
+desc "Migrate the database through scripts in db/migrate"
+task :migrate do
+ ActiveRecord::Migrator.migrate("db/migrations/")
+end
+
+desc "Reset the db and start over"
+task :reset do
+ File.unlink(CONFIG['database']['database'])
+ ActiveRecord::Migrator.migrate("db/migrations/")
+end