Sha256: 48c9d554fa86c79611e0cfd79afb6db22f8e80c6728aecd97e8f35fb0a71f420

Contents?: true

Size: 589 Bytes

Versions: 3

Compression:

Stored size: 589 Bytes

Contents

class PenteraTasks < Thor
  include Rails.application.config.dradis.thor_helper_module

  namespace 'dradis:plugins:pentera'

  desc      'upload FILE', 'upload Pentera results in JSON format'
  long_desc 'This plugin expects a JSON file generated by Pentera'
  def upload(file_path)
    require 'config/environment'

    unless File.exists?(file_path)
      $stderr.puts "** the file [#{file_path}] does not exist"
      exit(-1)
    end

    detect_and_set_project_scope

    importer = Dradis::Plugins::Pentera::Importer.new(task_options)
    importer.import(file: file_path)
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
dradis-pentera-4.15.0 lib/tasks/thorfile.rb
dradis-pentera-4.14.0 lib/tasks/thorfile.rb
dradis-pentera-4.13.0 lib/tasks/thorfile.rb