Sha256: 85a3a45825629bd9382985352d4abd65e590d8865365b694e5922d30ee4ff453

Contents?: true

Size: 748 Bytes

Versions: 5

Compression:

Stored size: 748 Bytes

Contents

# frozen_string_literal: true

require "thor"

require "mihari/mixins/hash"

require "mihari/cli/mixins/utils"

module Mihari
  module CLI
    class Base < Thor
      include Mihari::Mixins::Hash
      include Mixins::Utils

      class_option :config, type: :string, desc: "Path to the config file"

      class_option :ignore_old_artifacts, type: :boolean, default: false, desc: "Whether to ignore old artifacts from checking or not. Only affects with analyze commands."
      class_option :ignore_threshold, type: :numeric, default: 0, desc: "Number of days to define whether an artifact is old or not. Only affects with analyze commands."

      class << self
        def exit_on_failure?
          true
        end
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
mihari-3.3.0 lib/mihari/cli/base.rb
mihari-3.2.0 lib/mihari/cli/base.rb
mihari-3.1.0 lib/mihari/cli/base.rb
mihari-3.0.1 lib/mihari/cli/base.rb
mihari-3.0.0 lib/mihari/cli/base.rb