mixlib-install 3.12.5 → 3.12.16

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: fb233e51e18e929105c7c97d7f1ca060e4dc02bb31c96fe593bdcda077e7f57a
4
- data.tar.gz: 874ef20231f17e3bf00a0b5f9a8f6ad6c428793be44a897edb1b878449cdf86e
3
+ metadata.gz: ec3861ccec397037213914d6771aa0aae521352ddb66528c60c10671249d197c
4
+ data.tar.gz: 24971de31f5b8d96c10e2f8d1e1b7c71b1a3f9145b8d59f9b1d866b798b8ab07
5
5
  SHA512:
6
- metadata.gz: 267808104df5f1e62d9a11b067ed53f75bf540465b5a1a5065d76dacb7618ba20acc381616a19d287d8dcbc996b2ee94fe53ca5e8f7856512abad827ad69a3c5
7
- data.tar.gz: 123e1017d5c41f2a02be2723e8cacda065363ef5bd6f3af858e46c38a0099ead3bf7b8d2a687dbd4206e4986d0798d19f76014f5fc53c096b66a956b956ac793
6
+ metadata.gz: f4f0d069938b08e3d2e9d50f02d46cd71d85d16b6f0faa47625ac4bdf18548aec873c6c1db9ca4d14d741f0832682a90de1fdc507593b5dd454263eda6db170a
7
+ data.tar.gz: 8d1e2cc4d0c9775ddcf120f496648e4ee759c092bfff38d7bafc5402f353c15c0b49c1d03135b8401b4eef51bf902b3932268a5a79967171d99b08a8802960c1
data/Gemfile CHANGED
@@ -2,31 +2,31 @@ source "https://rubygems.org"
2
2
 
3
3
  gemspec
4
4
 
5
- group :docs do
6
- gem "github-markup"
7
- gem "redcarpet"
8
- gem "yard"
9
- end
5
+ gem "chef-utils", "= 16.6.14" if RUBY_VERSION < "2.6.0"
10
6
 
11
7
  group :test do
12
8
  gem "rake"
13
9
  gem "rspec"
14
10
  gem "vcr"
11
+ gem "webrick"
15
12
  gem "webmock", "~> 3.4"
16
13
  gem "aruba", "~> 0.14"
17
14
  gem "cucumber", "~> 1.3.20"
18
- gem "climate_control"
15
+ gem "contracts", "~> 0.16.0" # this entry can go away when ruby < 3 support is gone
16
+ if RUBY_VERSION < "2.5.0"
17
+ gem "climate_control", "= 0.1.0"
18
+ else
19
+ gem "climate_control", "~> 1.0"
20
+ end
19
21
  end
20
22
 
21
- if RUBY_VERSION =~ /^2/
22
- group :chefstyle do
23
- gem "chefstyle", "~> 0.4.0"
24
- end
23
+ # use old chefstyle to support TargetRubyVersion of 1.9
24
+ group :chefstyle do
25
+ gem "chefstyle", "~> 0.4.0"
25
26
  end
26
27
 
27
28
  group :debug do
28
29
  gem "pry"
29
30
  gem "pry-byebug"
30
- gem "pry-stack_explorer", "~> 0.4.0" # pin until we drop ruby < 2.6
31
31
  gem "rb-readline"
32
32
  end
data/Rakefile CHANGED
@@ -40,13 +40,6 @@ task "matrix" do
40
40
  end
41
41
  end
42
42
 
43
- begin
44
- require "yard"
45
- YARD::Rake::YardocTask.new(:docs)
46
- rescue LoadError
47
- puts "yard is not available. bundle install first to make sure all dependencies are installed."
48
- end
49
-
50
43
  task :console do
51
44
  require "irb"
52
45
  require "irb/completion"
@@ -184,7 +184,7 @@ module Mixlib
184
184
  # to disallow unsigned powershell scripts. This changes it for just this
185
185
  # powershell session, which allows this to run even if the execution policy
186
186
  # is set higher.
187
- Mixlib::ShellOut.new("powershell.exe -file #{File.join(d, "detect_platform.ps1")}", :env => { "PSExecutionPolicyPreference" => "Bypass" }).run_command
187
+ Mixlib::ShellOut.new("powershell.exe -NoProfile -file #{File.join(d, "detect_platform.ps1")}", :env => { "PSExecutionPolicyPreference" => "Bypass" }).run_command
188
188
  end
189
189
  else
190
190
  Mixlib::ShellOut.new(detect_platform_sh).run_command
@@ -14,7 +14,7 @@
14
14
  # $filetype: Type of the file downloaded.
15
15
  ############
16
16
 
17
- filename=`echo $download_url | sed -e 's/^.*\///'`
17
+ filename=`echo $download_url | sed -e 's/?.*//' | sed -e 's/^.*\///'`
18
18
  filetype=`echo $filename | sed -e 's/^.*\.//'`
19
19
 
20
20
  # use either $tmp_dir, the provided directory (-d) or the provided filename (-f)
@@ -15,7 +15,7 @@ if test "x$version" = "x" -a "x$CI" != "xtrue"; then
15
15
  echo "You are installing a package without a version pin. If you are installing"
16
16
  echo "on production servers via an automated process this is DANGEROUS and you will"
17
17
  echo "be upgraded without warning on new releases, even to new major releases."
18
- echo "Letting the version float is only appropriate in desktop, test, development or"
18
+ echo "Letting the version float is only appropriate in test, development or"
19
19
  echo "CI/CD environments."
20
20
  echo
21
21
  echo "WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING"
@@ -79,14 +79,14 @@ function Get-WebContentOnFullNet {
79
79
  $wc.Headers.Add("user-agent", "<%= user_agent_string %>")
80
80
  $proxy.Address = $env:http_proxy
81
81
  $bypassList = $env:no_proxy
82
-
82
+
83
83
 
84
84
  if($bypassList -ne $null){
85
-
85
+
86
86
  $bypassList = $bypassList.split(",")
87
87
  $proxy.BypassList = $byPassList
88
88
  }
89
-
89
+
90
90
  $wc.Proxy = $proxy
91
91
 
92
92
  if ([string]::IsNullOrEmpty($filepath)) {
@@ -180,9 +180,16 @@ function Get-WMIQuery {
180
180
  param ($class)
181
181
 
182
182
  if(Get-Command -Name Get-CimInstance -ErrorAction SilentlyContinue) {
183
- Get-CimInstance $class
183
+ try{
184
+ $classObject = Get-CimInstance $class
185
+ # If the Get-CimInstance command exists but fails due to security settings, try Get-WmiObject.
186
+ }
187
+ catch {
188
+ $classObject = Get-WmiObject $class
189
+ }
184
190
  }
185
191
  else {
186
- Get-WmiObject $class
192
+ $classObject = Get-WmiObject $class
187
193
  }
194
+ return $classObject
188
195
  }
@@ -73,7 +73,7 @@ function Install-Project {
73
73
 
74
74
  $cached_installer_available = $false
75
75
  $verify_checksum = $true
76
-
76
+
77
77
  if (-not [string]::IsNullOrEmpty($download_url_override)) {
78
78
  $download_url = $download_url_override
79
79
  $sha256 = $checksum
@@ -91,7 +91,7 @@ function Install-Project {
91
91
  }
92
92
  }
93
93
  else {
94
- $filename = ($download_url -split '/')[-1]
94
+ $filename = (([System.Uri]$download_url).AbsolutePath -split '/')[-1]
95
95
  }
96
96
  Write-Verbose "Download directory: $download_directory"
97
97
  Write-Verbose "Filename: $filename"
@@ -233,7 +233,7 @@ Must be one of: #{SUPPORTED_SHELL_TYPES.join(", ")}
233
233
  def validate_platform_options
234
234
  unless all_or_none?(platform_info.values)
235
235
  errors << <<-EOS
236
- Must provide platform, platform version and architecture when specifying any platform details
236
+ Must provide platform (-p), platform version (-l) and architecture (-a) when specifying any platform details
237
237
  EOS
238
238
  end
239
239
  end
@@ -1,5 +1,5 @@
1
1
  module Mixlib
2
2
  class Install
3
- VERSION = "3.12.5"
3
+ VERSION = "3.12.16"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mixlib-install
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.12.5
4
+ version: 3.12.16
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thom May
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2020-11-02 00:00:00.000000000 Z
12
+ date: 2021-08-14 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: mixlib-shellout
@@ -117,7 +117,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
117
117
  - !ruby/object:Gem::Version
118
118
  version: '0'
119
119
  requirements: []
120
- rubygems_version: 3.0.3
120
+ rubygems_version: 3.1.4
121
121
  signing_key:
122
122
  specification_version: 4
123
123
  summary: A library for interacting with Chef Software Inc's software distribution