Sha256: e4005afd9b133d58a9e5a4b934de98eb7a576804060a4526a5fceaba5c31d131
Contents?: true
Size: 909 Bytes
Versions: 14
Compression:
Stored size: 909 Bytes
Contents
module LicenseFinder module CLI class Blacklist < Base extend Subcommand include MakesDecisions desc 'list', 'List all the blacklisted licenses' def list say 'Blacklisted Licenses:', :blue say_each(decisions.blacklisted, &:name) end auditable desc 'add LICENSE...', 'Add one or more licenses to the blacklist' def add(*licenses) assert_some licenses modifying { licenses.each { |l| decisions.blacklist(l, txn) } } say "Added #{licenses.join(', ')} to the license blacklist" end auditable desc 'remove LICENSE...', 'Remove one or more licenses from the blacklist' def remove(*licenses) assert_some licenses modifying { licenses.each { |l| decisions.unblacklist(l, txn) } } say "Removed #{licenses.join(', ')} from the license blacklist" end end end end
Version data entries
14 entries across 14 versions & 1 rubygems