inspec-core 4.37.17 → 4.37.20

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 72cf7b34a66e5b4d2e79329b3530d14e16f5d6eaf75b76322d8e926655573ed4
4
- data.tar.gz: dd99f49c67c10ca4d97f464331aab65cf286f5ffa355526b8dc39c62ef0620f6
3
+ metadata.gz: 0e824612959dfc0663c92583fa5a542300d6953bcd32b28cfabf48b0709b9bf6
4
+ data.tar.gz: 79edead9df8512f94c9472bead2afd509b080f30e68630c912208734dc0b7bf1
5
5
  SHA512:
6
- metadata.gz: 2dc77b50b2fa6bc122ac9458030c6a905e56dfbee365dfe21118ec5d26eb87fc0019b035a0e5860c4863289a50a82a8528745db9c1318567d39971cfe90100be
7
- data.tar.gz: a53f07e9e2b52be166ca2c33afa68db9c424efb6f47e3fd4b741f913e6d667a6f57a5f59ec835ec7ed23caf88c9c60ee10a23f1f000e2c931b5535777934eeb3
6
+ metadata.gz: fba880eaf388b7ebb28a731ddaaab23a6c0b4f8a75ee70315c75f68d05445cc32c7c09109e5f9a696d8257111d5cf520409bf2d18079255fc7cce9376a3e87e3
7
+ data.tar.gz: e5bf78b8ee6a067ca8762326093f92c26f97b1c102b0198ec3a494a520bb0a6fc137ff2d6f992e36e3ff690389c2082b3f92484a79266e91e7359a25d8719df7
@@ -181,7 +181,7 @@ module Inspec
181
181
  puts " Patents: chef.io/patents\n\n"
182
182
  end
183
183
 
184
- def self.format_platform_info(params: {}, indent: 0, color: 39)
184
+ def self.format_platform_info(params: {}, indent: 0, color: 39, enable_color: true)
185
185
  str = ""
186
186
  params.each do |item, info|
187
187
  data = info
@@ -192,7 +192,7 @@ module Inspec
192
192
  # Do not output fields of data is missing ('unknown' is fine)
193
193
  next if data.nil?
194
194
 
195
- data = "\e[1m\e[#{color}m#{data}\e[0m"
195
+ data = "\e[1m\e[#{color}m#{data}\e[0m" if enable_color
196
196
  str << format("#{" " * indent}%-10s %s\n", item.to_s.capitalize + ":", data)
197
197
  end
198
198
  str
data/lib/inspec/cli.rb CHANGED
@@ -305,7 +305,7 @@ class Inspec::InspecCLI < Inspec::BaseCLI
305
305
  puts res.to_json
306
306
  else
307
307
  ui.headline("Platform Details")
308
- ui.plain Inspec::BaseCLI.format_platform_info(params: res, indent: 0, color: 36)
308
+ ui.plain Inspec::BaseCLI.format_platform_info(params: res, indent: 0, color: 36, enable_color: ui.color?)
309
309
  end
310
310
  rescue ArgumentError, RuntimeError, Train::UserError => e
311
311
  $stderr.puts e.message
@@ -1,3 +1,3 @@
1
1
  module Inspec
2
- VERSION = "4.37.17".freeze
2
+ VERSION = "4.37.20".freeze
3
3
  end
@@ -13,10 +13,9 @@ module InspecPlugins
13
13
  long_desc <<-LONGDESC
14
14
  `login` allows you to use InSpec with #{AUTOMATE_PRODUCT_NAME} Server
15
15
 
16
- You need to a token for communication. More information about token retrieval
16
+ You need to have a token for communication. More information about token retrieval
17
17
  is available at:
18
- https://docs.chef.io/api_automate.html#authentication-methods
19
- https://docs.chef.io/api_compliance.html#obtaining-an-api-token
18
+ https://docs.chef.io/automate/api_tokens
20
19
  LONGDESC
21
20
  option :insecure, aliases: :k, type: :boolean,
22
21
  desc: 'Explicitly allows InSpec to perform "insecure" SSL connections and transfers'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: inspec-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.37.17
4
+ version: 4.37.20
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chef InSpec Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-05-19 00:00:00.000000000 Z
11
+ date: 2021-05-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: chef-telemetry