mirror of
https://github.com/inspec/inspec
synced 2024-11-10 23:24:18 +00:00
Merge pull request #1376 from chef/chris-rock/supermarket-cli
print name for supermarket profiles
This commit is contained in:
commit
dad96a0311
2 changed files with 2 additions and 2 deletions
|
@ -12,7 +12,7 @@ module Supermarket
|
|||
# displays a list of profiles
|
||||
def self.profiles(supermarket_url = SUPERMARKET_URL)
|
||||
url = "#{supermarket_url}/api/v1/tools-search"
|
||||
_success, data = get(url, { type: 'compliance_profile', items: 100, order: 'recently_added' })
|
||||
_success, data = get(url, { type: 'compliance_profile', items: 100 })
|
||||
if !data.nil?
|
||||
profiles = JSON.parse(data)
|
||||
profiles['items'].map { |x|
|
||||
|
|
|
@ -22,7 +22,7 @@ module Supermarket
|
|||
|
||||
headline('Available profiles:')
|
||||
supermarket_profiles.each { |p|
|
||||
li("#{p['tool_owner']}/#{p['slug']}")
|
||||
li("#{p['tool_name']} #{mark_text(p['tool_owner'] + '/' + p['slug'])}")
|
||||
}
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue