Sha256: 873b5e51cc7771ace979ca84a4ea5773d7d06a688a657b2a9ee8375e7a8a02c9

Contents?: true

Size: 786 Bytes

Versions: 43

Compression:

Stored size: 786 Bytes

Contents

# frozen_string_literal: true

module LicenseFinder
  module CLI
    class IgnoredDependencies < Base
      extend Subcommand
      include MakesDecisions

      desc 'list', 'List all the ignored dependencies'
      def list
        say 'Ignored Dependencies:', :blue
        say_each(decisions.ignored)
      end

      auditable
      desc 'add DEPENDENCY', 'Add a dependency to be ignored'
      def add(dep)
        modifying { decisions.ignore(dep, txn) }

        say "Added #{dep} to the ignored dependencies"
      end

      auditable
      desc 'remove DEPENDENCY', 'Remove a dependency from the ignored dependencies'
      def remove(dep)
        modifying { decisions.heed(dep, txn) }

        say "Removed #{dep} from the ignored dependencies"
      end
    end
  end
end

Version data entries

43 entries across 43 versions & 2 rubygems

Version Path
license_finder-6.15.0 lib/license_finder/cli/ignored_dependencies.rb
gitlab-license_finder-6.14.2.1 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.14.2 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.14.1 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.13.0 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.12.2 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.12.1 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.12.0 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.11.0 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.10.1 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.10.0 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.9.0 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.8.2 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.8.1 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.8.0 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.7.0 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.6.2 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.6.1 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.6.0 lib/license_finder/cli/ignored_dependencies.rb
license_finder-6.5.0 lib/license_finder/cli/ignored_dependencies.rb