0
0
Fork 0

Add tootctl cache clear (#10689)

This commit is contained in:
Eugen Rochko 2019-05-04 01:02:57 +02:00 committed by GitHub
parent 5f9f610a23
commit 8025a41a1f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 23 additions and 0 deletions

19
lib/mastodon/cache_cli.rb Normal file
View file

@ -0,0 +1,19 @@
# frozen_string_literal: true
require_relative '../../config/boot'
require_relative '../../config/environment'
require_relative 'cli_helper'
module Mastodon
class CacheCLI < Thor
def self.exit_on_failure?
true
end
desc 'clear', 'Clear out the cache storage'
def clear
Rails.cache.clear
say('OK', :green)
end
end
end