about summary refs log tree commit diff
path: root/lib/tasks/mastodon.rake
diff options
context:
space:
mode:
Diffstat (limited to 'lib/tasks/mastodon.rake')
-rw-r--r--lib/tasks/mastodon.rake7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/tasks/mastodon.rake b/lib/tasks/mastodon.rake
index 29e4494c4..aa07c0738 100644
--- a/lib/tasks/mastodon.rake
+++ b/lib/tasks/mastodon.rake
@@ -41,4 +41,11 @@ namespace :mastodon do
       $redis.keys('feed:*').each { |key| $redis.del(key) }
     end
   end
+
+  namespace :graphs do
+    desc 'Syncs all follow relationships to Neo4J'
+    task sync: :environment do
+      Follow.find_each(&:sync!)
+    end
+  end
 end