chef-cli 3.1.3 → 3.1.6

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: 7aef40ff73580003cb8253f756a4da57c36c0fa7266e9df50fa5b3ff877b2c2b
4
- data.tar.gz: a041fb63c6b24c45ddc3f90e40f8abf1f876cdeb3655ce1c2be09d87f17eb42a
3
+ metadata.gz: db59602ecc8f8eccfed56173f71092e36e1cc55ad6ece88e311d26896d7a1e0b
4
+ data.tar.gz: a584cf195ad81b8e3ddae995aa5c275545e795782439990ceb11e7dc2450eba6
5
5
  SHA512:
6
- metadata.gz: 0361a3d6fe8f08665baebc4b69e931f6ed1546288d705c5cb2e09ce208712674afbb2ff07e4c6a45a1e9db1e5cb05b5788d2171af6280b594ed50f3a940335cb
7
- data.tar.gz: d731fea15f7a1996687719a7f804e475020cef4d52f2da38b852ddd2e43c06f0493571cdb373ec23e3220d2fa1ac1e51aed7edf95cecf539a0c39a747f23b92b
6
+ metadata.gz: d1d34379eda31b8391fd142cc60ad71c0ac8bcd9e8a0fc9734da1a25cbfebdae1b2dda323ef6937ba2a05d11a86cc429f8a6d4692067d073b240dd5da3fdc5a2
7
+ data.tar.gz: 27b7a7342e77162a34a7c6e3dcabfc9ba73d3081fb2b1bc6d144c5d01a8fa673bc2c60f6fc87ee2cc3841a970274f407b6cf9ab2c099d4cd6e7fdd845066c10c
@@ -1,10 +1,9 @@
1
+
1
2
  # Fish Shell command-line completions for <%=ChefCLI::Dist::PRODUCT %>
2
3
 
3
- function __fish_chef_no_command --description 'Test if chef has yet to be given the main command'
4
- set -l cmd (commandline -opc)
5
- test (count $cmd) -eq 1
6
- end
4
+ # set a list of all the chef commands in the Ruby chef-cli
5
+ set -l chef_commands <%= commands.keys.join(' ') %>;
7
6
 
8
7
  <% commands.each do |command, desc| -%>
9
- complete -c chef -f -n '__fish_chef_no_command' -a <%= command %> -d "<%= desc %>"
8
+ complete -c chef -f -n "not __fish_seen_subcommand_from $chef_commands" -a <%= command %> -d "<%= desc %>";
10
9
  <% end -%>
@@ -87,7 +87,7 @@ module ChefCLI
87
87
  # On Mac we place all of our symlinks under /usr/local/bin on other
88
88
  # platforms they are under /usr/bin
89
89
  def usr_bin_prefix
90
- @usr_bin_prefix ||= os_x? ? "/usr/local/bin" : "/usr/bin"
90
+ @usr_bin_prefix ||= macos? ? "/usr/local/bin" : "/usr/bin"
91
91
  end
92
92
 
93
93
  # Returns the full path to the given command under usr_bin_prefix
@@ -166,8 +166,11 @@ module ChefCLI
166
166
  end
167
167
  end
168
168
 
169
- # Returns true if we are on Mac OS X. Otherwise false
170
- def os_x?
169
+ # @return [Boolean] Returns true if we are on macOS. Otherwise false
170
+ #
171
+ # @api private
172
+ #
173
+ def macos?
171
174
  !!(RUBY_PLATFORM =~ /darwin/)
172
175
  end
173
176
  end
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  driver:
3
3
  name: dokken
4
+ privileged: true # allows systemd services to start
4
5
 
5
6
  provisioner:
6
7
  name: dokken
@@ -16,5 +16,5 @@
16
16
  #
17
17
 
18
18
  module ChefCLI
19
- VERSION = "3.1.3".freeze
19
+ VERSION = "3.1.6".freeze
20
20
  end
@@ -264,8 +264,8 @@ describe ChefCLI::Command::ShellInit do
264
264
  {
265
265
  "exec" => "Runs the command in context of the embedded ruby",
266
266
  "env" => "Prints environment variables used by #{ChefCLI::Dist::PRODUCT}",
267
- "gem" => "Runs the `gem` command in context of the embedded ruby",
268
- "generate" => "Generate a new app, cookbook, or component",
267
+ "gem" => "Runs the `gem` command in context of the embedded Ruby",
268
+ "generate" => "Generate a new repository, cookbook, or other component",
269
269
  }
270
270
  end
271
271
 
@@ -276,17 +276,17 @@ describe ChefCLI::Command::ShellInit do
276
276
 
277
277
  let(:expected_completion_function) do
278
278
  <<~END_COMPLETION
279
+
279
280
  # Fish Shell command-line completions for #{ChefCLI::Dist::PRODUCT}
280
281
 
281
- function __fish_chef_no_command --description 'Test if chef has yet to be given the main command'
282
- set -l cmd (commandline -opc)
283
- test (count $cmd) -eq 1
284
- end
282
+ # set a list of all the chef commands in the Ruby chef-cli
283
+ set -l chef_commands exec env gem generate;
284
+
285
+ complete -c chef -f -n "not __fish_seen_subcommand_from $chef_commands" -a exec -d "Runs the command in context of the embedded ruby";
286
+ complete -c chef -f -n "not __fish_seen_subcommand_from $chef_commands" -a env -d "Prints environment variables used by #{ChefCLI::Dist::PRODUCT}";
287
+ complete -c chef -f -n "not __fish_seen_subcommand_from $chef_commands" -a gem -d "Runs the `gem` command in context of the embedded Ruby";
288
+ complete -c chef -f -n "not __fish_seen_subcommand_from $chef_commands" -a generate -d "Generate a new repository, cookbook, or other component";
285
289
 
286
- complete -c chef -f -n '__fish_chef_no_command' -a exec -d "Runs the command in context of the embedded ruby"
287
- complete -c chef -f -n '__fish_chef_no_command' -a env -d "Prints environment variables used by Chef Workstation"
288
- complete -c chef -f -n '__fish_chef_no_command' -a gem -d "Runs the `gem` command in context of the embedded ruby"
289
- complete -c chef -f -n '__fish_chef_no_command' -a generate -d "Generate a new app, cookbook, or component"
290
290
  END_COMPLETION
291
291
  end
292
292
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chef-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.3
4
+ version: 3.1.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chef Software, Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-03-02 00:00:00.000000000 Z
11
+ date: 2021-03-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mixlib-cli