You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
462 B

  1. # frozen_string_literal: true
  2. task stats: 'mastodon:stats'
  3. namespace :mastodon do
  4. desc 'Report code statistics (KLOCs, etc)'
  5. task :stats do
  6. require 'rails/code_statistics'
  7. [
  8. %w(App\ Libraries app/lib),
  9. %w(Presenters app/presenters),
  10. %w(Services app/services),
  11. %w(Validators app/validators),
  12. %w(Workers app/workers),
  13. ].each do |name, dir|
  14. ::STATS_DIRECTORIES << [name, Rails.root.join(dir)]
  15. end
  16. end
  17. end