Sha256: e6bf04a9a492ad8ea9dd3173f9feb8d9f054cd75e310155629b0b9da7e727b6d

Contents?: true

Size: 1.12 KB

Versions: 66

Compression:

Stored size: 1.12 KB

Contents

# @note All options not specific to any given rake task should go in the .yardopts file so they are available to both
#   the below rake tasks and when invoking `yard` from the command line

if defined? YARD
  namespace :yard do
    YARD::Rake::YardocTask.new(:doc) do |t|
      # --no-stats here as 'stats' task called after will print fuller stats
      t.options = ['--no-stats']

      t.after = Proc.new {
        Rake::Task['yard:stats'].execute
      }
    end

    # need environment so that yard templates can load ActiveRecord::Base subclasses for Entity-Relationship Diagrams
    task :doc => :eager_load

    desc "Shows stats for YARD Documentation including listing undocumented modules, classes, constants, and methods"
    task :stats => :environment do
      stats = YARD::CLI::Stats.new
      stats.run('--compact', '--list-undoc')
    end
  end

  # @todo Figure out how to just clone description from yard:doc
  desc "Generate YARD documentation"
  # allow calling namespace to as a task that goes to default task for namespace
  task :yard => ['yard:doc']
end

task eager_load: :environment do
  Rails.application.eager_load!
end

Version data entries

66 entries across 66 versions & 1 rubygems

Version Path
metasploit_data_models-0.24.5 lib/tasks/yard.rake
metasploit_data_models-0.24.1.pre.rspec.pre.3.pre.1 lib/tasks/yard.rake
metasploit_data_models-0.24.1 lib/tasks/yard.rake
metasploit_data_models-1.0.0.pre.rails.pre.4.0b lib/tasks/yard.rake
metasploit_data_models-1.0.0.pre.rails.pre.4.0a lib/tasks/yard.rake
metasploit_data_models-0.24.0 lib/tasks/yard.rake
metasploit_data_models-0.23.3.pre.autoload lib/tasks/yard.rake
metasploit_data_models-0.23.2 lib/tasks/yard.rake
metasploit_data_models-0.23.2-java lib/tasks/yard.rake
metasploit_data_models-0.23.1 lib/tasks/yard.rake
metasploit_data_models-0.23.1-java lib/tasks/yard.rake
metasploit_data_models-0.23.0 lib/tasks/yard.rake
metasploit_data_models-0.23.0-java lib/tasks/yard.rake
metasploit_data_models-0.22.8 lib/tasks/yard.rake
metasploit_data_models-0.22.8-java lib/tasks/yard.rake
metasploit_data_models-0.22.7 lib/tasks/yard.rake
metasploit_data_models-0.22.7-java lib/tasks/yard.rake
metasploit_data_models-0.22.6 lib/tasks/yard.rake
metasploit_data_models-0.22.6-java lib/tasks/yard.rake
metasploit_data_models-0.22.5 lib/tasks/yard.rake