Sha256: c7c0a099dbec21a730d246f5288ae7590f4eee33e511bcdee48e9acd05ebcbc0

Contents?: true

Size: 673 Bytes

Versions: 5

Compression:

Stored size: 673 Bytes

Contents

# frozen_string_literal: true

module Spandx
  module Cli
    module Commands
      class Index
        class Build < Spandx::Cli::Command
          def initialize(options)
            @options = options
          end

          def execute(output: $stdout)
            catalogue = Spandx::Spdx::Catalogue.from_git
            indexes.each do |index|
              index.update!(catalogue: catalogue, output: output)
            end
            output.puts 'OK'
          end

          private

          def indexes
            [
              Spandx::Dotnet::Index.new(directory: @options[:directory])
            ]
          end
        end
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
spandx-0.10.1 lib/spandx/cli/commands/index/build.rb
spandx-0.10.0 lib/spandx/cli/commands/index/build.rb
spandx-0.9.0 lib/spandx/cli/commands/index/build.rb
spandx-0.8.0 lib/spandx/cli/commands/index/build.rb
spandx-0.7.0 lib/spandx/cli/commands/index/build.rb