ruby-jss 2.1.0b4 → 2.1.0b5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5a00af3813560fa65f8597fc6a516d1b9933eb333f2aee3478646df1f93a45b9
4
- data.tar.gz: 892e4f5ed6b7271c55377671ff13ccb7778a51b34d57b9da67086cd95ec7d0ca
3
+ metadata.gz: 3e4edfd42bf486020f780c565948d0b6de6db11413eaaf2f5a486243d8137a76
4
+ data.tar.gz: 0c3b1e370c9f1ffdcf97f7174b0dbc508f3c414efc5a86a0b5b09e0c42ba4e3f
5
5
  SHA512:
6
- metadata.gz: 6461d576566cfd365c77ff36758a8c9558deb2bad8936b87be03f12dd3c7f7662734ec2eaaa7f1f4b5b83c9bb0264c9e06609c2f8f0ef20106d3c8db8be45484
7
- data.tar.gz: 30a9a4dcf60a9aa0a25c4a64429e34f1f8cf6cf9609f80c94b675c0e498f74f46f3fc0842fab2d20ed248f0a792c2349a7373a273905ec45c3994b3b6f4fc3eb
6
+ metadata.gz: 7fd967954cc7642ec10054fff0c2d75f3dd30bce1836baf158a1fb4abe4f5d8a95ca493e9c1ef2b03fe1490874fdbf3f42b81af46389c7a86a6a73bdaeb867c2
7
+ data.tar.gz: f806304ae8b9fad9fae2ffc35b77681a26cf2bfd63dc202b5a52f25b43e2e278fda62321f05e0c3f47a6e063238b5eda86ec870814a971fb13e7631ecfa04f5a
data/CHANGES.md CHANGED
@@ -18,21 +18,22 @@ Many many thanks to actae0n of Blacksun Hackers Club for reporting this issue an
18
18
 
19
19
  ### Added
20
20
 
21
- - Support for the `/v1/jamf-management-framework/redeploy/{id}` Jamf Pro API endpoint in `Jamf::Computer` and
21
+ - Support for the `/v1/jamf-management-framework/redeploy/{id}` Jamf Pro API endpoint in `Jamf::Computer` and
22
22
  `Jamf::ComputerGroup`. The method `redeploy_mgmt_framework` is both a Class and an Instance method for those classes
23
23
  - The instance method sends the redeployment to the single computer or all the members of the single computer group.
24
- - The class method accepts a single id, or an array of ids.
24
+ - The class method accepts a single id, or an array of ids.
25
25
  - When using `Jamf::Computer.redeploy_mgmt_framework` provide computer ids
26
26
  - When using `Jamf::ComputerGroup.redeploy_mgmt_framework` provide group ids, and all members of all groups will get
27
27
  the redeployment
28
- - In all cases the result is a Hash of target computer ids (keys) and result value for each (Strings).
29
- - The result is either the UUID of the sent MDM command, or an error message if the MDM command couldn't be sent.
30
- - All the code is in the `Jamf::MacOSRedeployMgmtFramework` module, q.v. in the [rubydoc documentation](https://www.rubydoc.info/gems/ruby-jss/Jamf/MacOSRedeployMgmtFramework)
28
+ - In all cases the result is a Hash of target computer ids (keys) and result value for each (Strings).
29
+ - The result is either the UUID of the sent MDM command, or an error message if the MDM command couldn't be sent.
30
+ - All the code is in the `Jamf::MacOSRedeployMgmtFramework` module, q.v. in the [rubydoc documentation](https://www.rubydoc.info/gems/ruby-jss/Jamf/MacOSRedeployMgmtFramework)
31
31
 
32
32
  ### Fixed
33
33
 
34
34
  - A few internal rescues of a deprecated exception class
35
35
  - Removed auto-loading of deprecation files; now explicitly loaded.
36
+ - A few Ruby 2 => Ruby 3 bugs - method params needing double-splats (Thanks to @Timelost for reporting this one)
36
37
 
37
38
  ## \[2.0.0] - 2022-09-12
38
39
 
data/bin/cgrouper CHANGED
@@ -23,10 +23,8 @@
23
23
  ### KIND, either express or implied. See the Apache License for the specific
24
24
  ### language governing permissions and limitations under the Apache License.
25
25
 
26
-
27
26
  # Create or change the membership of a computer group in the JSS
28
27
 
29
-
30
28
  # Load in the JSS library
31
29
  require 'jss-api'
32
30
 
@@ -44,9 +42,9 @@ class App
44
42
  [-S server] [-U user] [-T timeout] [-V] [--debug]
45
43
  group [-f /file/path ] [computer [computer ...]]"
46
44
 
47
- ACTIONS_NEEDING_GROUP = [ :create_group, :rename_group, :delete_group, :add_members, :remove_members, :remove_all, :list_members]
45
+ ACTIONS_NEEDING_GROUP = %i[create_group rename_group delete_group add_members remove_members remove_all list_members]
48
46
 
49
- ACTIONS_FOR_STATIC_GROUPS_ONLY = [:create_group, :add_members, :remove_members, :remove_all]
47
+ ACTIONS_FOR_STATIC_GROUPS_ONLY = %i[create_group add_members remove_members remove_all]
50
48
 
51
49
  #####################################
52
50
  ### Attributes
@@ -57,31 +55,30 @@ class App
57
55
  ###
58
56
  ### set up
59
57
  ###
60
- def initialize(args)
61
-
58
+ def initialize(**_args)
62
59
  @debug = false
63
60
 
64
61
  # define the options
65
62
  cli_opts = GetoptLong.new(
66
- [ '--help', '-h', '-H', GetoptLong::NO_ARGUMENT ],
67
- [ '--list-groups', '-L', GetoptLong::NO_ARGUMENT ],
68
- [ '--list-static', '-s', GetoptLong::NO_ARGUMENT ],
69
- [ '--list-smart', '-m', GetoptLong::NO_ARGUMENT ],
70
- [ '--create-group', '--create', '-c', GetoptLong::NO_ARGUMENT ],
71
- [ '--rename-group', '--rename', '-n', GetoptLong::REQUIRED_ARGUMENT ],
72
- [ '--delete-group', '--delete', '-d', GetoptLong::NO_ARGUMENT ],
73
- [ '--list-members', '--list-computers', '-l', GetoptLong::NO_ARGUMENT ],
74
- [ '--add-members', '--add', '-a', GetoptLong::NO_ARGUMENT ],
75
- [ '--remove-members', '--remove', '-r', GetoptLong::NO_ARGUMENT ],
76
- [ '--remove-all-members', '-R', GetoptLong::NO_ARGUMENT ],
77
- [ '--file', '-f', GetoptLong::REQUIRED_ARGUMENT ],
78
- [ '--server', '-S', GetoptLong::OPTIONAL_ARGUMENT],
79
- [ '--port', '-P', GetoptLong::OPTIONAL_ARGUMENT],
80
- [ '--user', '-U', GetoptLong::OPTIONAL_ARGUMENT],
81
- [ '--no-verify-cert', '-V', GetoptLong::NO_ARGUMENT],
82
- [ '--timeout', '-T', GetoptLong::OPTIONAL_ARGUMENT],
83
- [ '--no-confirm', '-C', GetoptLong::NO_ARGUMENT],
84
- [ '--debug', GetoptLong::NO_ARGUMENT]
63
+ ['--help', '-h', '-H', GetoptLong::NO_ARGUMENT],
64
+ ['--list-groups', '-L', GetoptLong::NO_ARGUMENT],
65
+ ['--list-static', '-s', GetoptLong::NO_ARGUMENT],
66
+ ['--list-smart', '-m', GetoptLong::NO_ARGUMENT],
67
+ ['--create-group', '--create', '-c', GetoptLong::NO_ARGUMENT],
68
+ ['--rename-group', '--rename', '-n', GetoptLong::REQUIRED_ARGUMENT],
69
+ ['--delete-group', '--delete', '-d', GetoptLong::NO_ARGUMENT],
70
+ ['--list-members', '--list-computers', '-l', GetoptLong::NO_ARGUMENT],
71
+ ['--add-members', '--add', '-a', GetoptLong::NO_ARGUMENT],
72
+ ['--remove-members', '--remove', '-r', GetoptLong::NO_ARGUMENT],
73
+ ['--remove-all-members', '-R', GetoptLong::NO_ARGUMENT],
74
+ ['--file', '-f', GetoptLong::REQUIRED_ARGUMENT],
75
+ ['--server', '-S', GetoptLong::OPTIONAL_ARGUMENT],
76
+ ['--port', '-P', GetoptLong::OPTIONAL_ARGUMENT],
77
+ ['--user', '-U', GetoptLong::OPTIONAL_ARGUMENT],
78
+ ['--no-verify-cert', '-V', GetoptLong::NO_ARGUMENT],
79
+ ['--timeout', '-T', GetoptLong::OPTIONAL_ARGUMENT],
80
+ ['--no-confirm', '-C', GetoptLong::NO_ARGUMENT],
81
+ ['--debug', GetoptLong::NO_ARGUMENT]
85
82
  )
86
83
 
87
84
  # here's where we hold cmdline args and other user options
@@ -92,68 +89,68 @@ class App
92
89
 
93
90
  # if stdin is not a tty, then we must assume
94
91
  # we're being passed a password
95
- @options.getpass = $stdin.tty? ? :prompt : :stdin
92
+ @options.getpass = $stdin.tty? ? :prompt : :stdin
96
93
 
97
94
  # parse the options
98
95
  cli_opts.each do |opt, arg|
99
96
  case opt
100
- when '--help'
101
- show_help
97
+ when '--help'
98
+ show_help
102
99
 
103
- when '--list-groups'
104
- @options.action = :list_groups
100
+ when '--list-groups'
101
+ @options.action = :list_groups
105
102
 
106
- when '--list-static'
107
- @options.action = :list_static
103
+ when '--list-static'
104
+ @options.action = :list_static
108
105
 
109
- when '--list-smart'
110
- @options.action = :list_smart
106
+ when '--list-smart'
107
+ @options.action = :list_smart
111
108
 
112
- when '--list-members'
113
- @options.action = :list_members
109
+ when '--list-members'
110
+ @options.action = :list_members
114
111
 
115
- when '--create-group'
116
- @options.action = :create_group
112
+ when '--create-group'
113
+ @options.action = :create_group
117
114
 
118
- when '--rename-group'
119
- @options.action = :rename_group
120
- @options.new_name = arg
115
+ when '--rename-group'
116
+ @options.action = :rename_group
117
+ @options.new_name = arg
121
118
 
122
- when '--delete-group'
123
- @options.action = :delete_group
119
+ when '--delete-group'
120
+ @options.action = :delete_group
124
121
 
125
- when '--add-members'
126
- @options.action = :add_members
122
+ when '--add-members'
123
+ @options.action = :add_members
127
124
 
128
- when '--remove-members'
129
- @options.action = :remove_members
125
+ when '--remove-members'
126
+ @options.action = :remove_members
130
127
 
131
- when '--remove-all-members'
132
- @options.action = :remove_all
128
+ when '--remove-all-members'
129
+ @options.action = :remove_all
133
130
 
134
- when '--file'
135
- @options.input_file = Pathname.new arg
131
+ when '--file'
132
+ @options.input_file = Pathname.new arg
136
133
 
137
- when '--server'
138
- @options.server = arg
134
+ when '--server'
135
+ @options.server = arg
139
136
 
140
- when '--port'
141
- @options.port = arg
137
+ when '--port'
138
+ @options.port = arg
142
139
 
143
- when '--user'
144
- @options.user = arg
140
+ when '--user'
141
+ @options.user = arg
145
142
 
146
- when '--no-verify-cert'
147
- @options.verify_cert = false
143
+ when '--no-verify-cert'
144
+ @options.verify_cert = false
148
145
 
149
- when '--timeout'
150
- @options.timeout = arg
146
+ when '--timeout'
147
+ @options.timeout = arg
151
148
 
152
- when '--no-confirm'
153
- @options.no_confirm = true
149
+ when '--no-confirm'
150
+ @options.no_confirm = true
154
151
 
155
- when '--debug'
156
- @debug = true
152
+ when '--debug'
153
+ @debug = true
157
154
 
158
155
  end # case
159
156
  end # opts.each
@@ -168,17 +165,13 @@ class App
168
165
 
169
166
  # will we say anything when finished?
170
167
  @done_msg = nil
171
-
172
168
  end # init
173
169
 
174
-
175
-
176
170
  #####################################
177
171
  ###
178
172
  ### Do It
179
173
  ###
180
174
  def run
181
-
182
175
  if @options.action == :none
183
176
  puts USAGE
184
177
  return
@@ -188,75 +181,73 @@ class App
188
181
  @options.user ||= JSS::CONFIG.api_username
189
182
  @options.server ||= JSS::CONFIG.api_server_name
190
183
 
191
- raise JSS::MissingDataError, "No JSS Username provided or found in the JSS gem config." unless @options.user
192
- raise JSS::MissingDataError, "No JSS Server provided or found in the JSS gem config." unless @options.server
193
-
194
- Jamf.cnx.connect( :server => @options.server,
195
- :port => @options.port,
196
- :verify_cert => @options.verify_cert,
197
- :user => @options.user,
198
- :pw => @options.getpass,
199
- :stdin_line => 1,
200
- :timeout => @options.timeout
201
- )
184
+ raise JSS::MissingDataError, 'No JSS Username provided or found in the JSS gem config.' unless @options.user
185
+ raise JSS::MissingDataError, 'No JSS Server provided or found in the JSS gem config.' unless @options.server
202
186
 
187
+ Jamf.cnx.connect(server: @options.server,
188
+ port: @options.port,
189
+ verify_cert: @options.verify_cert,
190
+ user: @options.user,
191
+ pw: @options.getpass,
192
+ stdin_line: 1,
193
+ timeout: @options.timeout)
203
194
 
204
195
  if ACTIONS_NEEDING_GROUP.include? @options.action
205
196
 
206
- raise JSS::MissingDataError, "Please specify a group name" unless @options.group
197
+ raise JSS::MissingDataError, 'Please specify a group name' unless @options.group
207
198
 
208
- # get the group from the API
209
- if @options.action == :create_group
210
- @group = JSS::ComputerGroup.make :name => @options.group, :type => :static
211
- else
212
- @group = JSS::ComputerGroup.fetch :name => @options.group
213
- end
199
+ # get the group from the API
200
+ @group = if @options.action == :create_group
201
+ JSS::ComputerGroup.make name: @options.group, type: :static
202
+ else
203
+ JSS::ComputerGroup.fetch name: @options.group
204
+ end
214
205
 
215
206
  end # if ACTIONS_NEEDING_GROUP
216
207
 
217
208
  # smart groups can't have some things done to them
218
- raise InvalidTypeError, "You can't do that to a smart group. Use the JSS WebApp if needed." if ACTIONS_FOR_STATIC_GROUPS_ONLY.include? @options.action and @group.smart?
219
-
209
+ if ACTIONS_FOR_STATIC_GROUPS_ONLY.include? @options.action and @group.smart?
210
+ raise InvalidTypeError,
211
+ "You can't do that to a smart group. Use the JSS WebApp if needed."
212
+ end
220
213
 
221
214
  case @options.action
222
215
 
223
- when :list_groups
224
- list_groups
216
+ when :list_groups
217
+ list_groups
225
218
 
226
- when :list_static
227
- list_groups :static
219
+ when :list_static
220
+ list_groups :static
228
221
 
229
- when :list_smart
230
- list_groups :smart
222
+ when :list_smart
223
+ list_groups :smart
231
224
 
232
- when :list_members
233
- list_members
225
+ when :list_members
226
+ list_members
234
227
 
235
- when :create_group
236
- create_group
228
+ when :create_group
229
+ create_group
237
230
 
238
- when :rename_group
239
- rename_group
231
+ when :rename_group
232
+ rename_group
240
233
 
241
- when :delete_group
242
- delete_group
234
+ when :delete_group
235
+ delete_group
243
236
 
244
- when :add_members
245
- add_members
237
+ when :add_members
238
+ add_members
246
239
 
247
- when :remove_members
248
- remove_members
240
+ when :remove_members
241
+ remove_members
249
242
 
250
- when :remove_all
251
- remove_all
243
+ when :remove_all
244
+ remove_all
252
245
 
253
246
  end # case @options.action
254
247
 
255
248
  puts "Done! #{@done_msg}" if @done_msg
256
-
257
249
  end # run
258
250
 
259
-
260
251
  #####################################
261
252
  ###
262
253
  ### Show Help
@@ -307,7 +298,6 @@ Notes:
307
298
  (spaces, tabs, & returns in any number or combination)
308
299
 
309
300
  FULLHELP
310
-
311
301
  end
312
302
 
313
303
  #####################################
@@ -316,21 +306,21 @@ Notes:
316
306
  ###
317
307
  def list_groups(show = :all)
318
308
  case show
319
- when :all
320
- label = "All"
321
- groups_to_show = JSS::ComputerGroup.all
322
- when :static
323
- label = "Static"
324
- groups_to_show = JSS::ComputerGroup.all_static
325
- when :smart
326
- label = "Smart"
327
- groups_to_show = JSS::ComputerGroup.all_smart
328
- end #case
309
+ when :all
310
+ label = 'All'
311
+ groups_to_show = JSS::ComputerGroup.all
312
+ when :static
313
+ label = 'Static'
314
+ groups_to_show = JSS::ComputerGroup.all_static
315
+ when :smart
316
+ label = 'Smart'
317
+ groups_to_show = JSS::ComputerGroup.all_smart
318
+ end # case
329
319
 
330
320
  puts "# #{label} computer groups in the JSS"
331
- puts "#---------------------------------------------"
321
+ puts '#---------------------------------------------'
332
322
 
333
- groups_to_show.sort{|a,b| a[:name].downcase <=> b[:name].downcase}.each do |grp|
323
+ groups_to_show.sort { |a, b| a[:name].downcase <=> b[:name].downcase }.each do |grp|
334
324
  puts grp[:name]
335
325
  end
336
326
  end
@@ -341,30 +331,26 @@ Notes:
341
331
  ###
342
332
  def list_members
343
333
  puts "# All members of JSS #{@group.smart? ? 'smart' : 'static'} computer group '#{@options.group}'"
344
- puts "#--- name (id) ---------------------------------"
334
+ puts '#--- name (id) ---------------------------------'
345
335
 
346
336
  # put them into a tmp array, so that
347
337
  # we can sort by computer name, remembering that
348
338
  # there can be duplicate names.
349
339
  list = []
350
- @group.members.each{|mem| list << "#{mem[:name]} (#{mem[:id]})" }
351
- puts list.sort #.join("\n")
340
+ @group.members.each { |mem| list << "#{mem[:name]} (#{mem[:id]})" }
341
+ puts list.sort # .join("\n")
352
342
  end
353
343
 
354
-
355
344
  #####################################
356
345
  ###
357
346
  ### Create a new group
358
347
  ###
359
348
  def create_group
360
-
361
349
  return unless confirm "create a new static group named '#{@options.group}'"
362
- @group.create
363
350
 
364
- unless @options.computers.empty?
365
- add_members
366
- end
351
+ @group.create
367
352
 
353
+ add_members unless @options.computers.empty?
368
354
  end
369
355
 
370
356
  #####################################
@@ -373,36 +359,36 @@ Notes:
373
359
  ###
374
360
  def rename_group
375
361
  return unless confirm "rename group '#{@group.name}' to '#{@options.new_name}'"
362
+
376
363
  @group.name = @options.new_name
377
364
  @group.update
378
365
  end
379
366
 
380
-
381
367
  #####################################
382
368
  ###
383
369
  ### delete a group
384
370
  ###
385
371
  def delete_group
386
372
  return unless confirm "DELETE group '#{@group.name}'"
373
+
387
374
  @group.delete
388
375
  end
389
376
 
390
-
391
377
  #####################################
392
378
  ###
393
379
  ### add members to a group
394
380
  ###
395
381
  def add_members
396
- raise JSS::MissingDataError, "No computer names provided" if @options.computers.empty?
382
+ raise JSS::MissingDataError, 'No computer names provided' if @options.computers.empty?
397
383
  raise JSS::UnsupportedError, "Smart group members can't be changed." if @group.smart?
398
384
  return unless @options.action == :create_group or confirm "add computers to group '#{@group.name}'"
399
385
 
400
386
  @options.computers.each do |c|
401
- begin
402
- @group.add_member c
403
- rescue JSS::NoSuchItemError
404
- puts "#{$!} - skipping"
405
- end # begin
387
+
388
+ @group.add_member c
389
+ rescue JSS::NoSuchItemError
390
+ puts "#{$!} - skipping"
391
+ # begin
406
392
  end # each
407
393
 
408
394
  @group.update
@@ -413,15 +399,16 @@ Notes:
413
399
  ### remove members from a group
414
400
  ###
415
401
  def remove_members
416
- raise JSS::MissingDataError, "No computer names provided" if @options.computers.empty?
402
+ raise JSS::MissingDataError, 'No computer names provided' if @options.computers.empty?
417
403
  raise JSS::UnsupportedError, "Smart group members can't be changed." if @group.smart?
418
404
  return unless confirm "remove computers from group '#{@group.name}'"
405
+
419
406
  @options.computers.each do |c|
420
- begin
421
- @group.remove_member c
422
- rescue JSS::NoSuchItemError
423
- puts "#{$!} - skipping"
424
- end
407
+
408
+ @group.remove_member c
409
+ rescue JSS::NoSuchItemError
410
+ puts "#{$!} - skipping"
411
+
425
412
  end
426
413
  @group.update
427
414
  end
@@ -433,11 +420,11 @@ Notes:
433
420
  def remove_all
434
421
  raise JSS::UnsupportedError, "Smart group members can't be changed." if @group.smart?
435
422
  return unless confirm "remove ALL computers from group '#{@group.name}'"
423
+
436
424
  @group.clear
437
425
  @group.update
438
426
  end
439
427
 
440
-
441
428
  #####################################
442
429
  ###
443
430
  ### Read computer names from a file
@@ -448,6 +435,7 @@ Notes:
448
435
  def get_computers_from_file
449
436
  raise JSS::NoSuchItemError "File #{@options.input_file} isn't a file or isn't readable." unless \
450
437
  @options.input_file.file? and @options.input_file.readable?
438
+
451
439
  @options.input_file.read.split(/\s+/)
452
440
  end
453
441
 
@@ -456,31 +444,26 @@ Notes:
456
444
  ### Get confirmation before doing something
457
445
  ### Returns true or false
458
446
  ###
459
- def confirm (action)
460
- return true if @options.no_confirm
447
+ def confirm(action)
448
+ return true if @options.no_confirm
461
449
 
462
- print "Really #{action}? (y/n): "
463
- $stdin.reopen '/dev/tty'
464
- reply = $stdin.gets.strip
465
- return true if reply =~ /^y/i
466
- return false
450
+ print "Really #{action}? (y/n): "
451
+ $stdin.reopen '/dev/tty'
452
+ reply = $stdin.gets.strip
453
+ return true if reply =~ /^y/i
467
454
 
455
+ false
468
456
  end # confirm
469
457
 
470
-
471
458
  end # class App
472
459
 
473
460
  #######################################
474
461
  begin
475
462
  app = App.new(ARGV)
476
463
  app.run
477
-
478
464
  rescue
479
465
  # handle exceptions not handled elsewhere
480
466
  puts "An error occurred: #{$!}"
481
- puts "Backtrace:" if app.debug
467
+ puts 'Backtrace:' if app.debug
482
468
  puts $@ if app.debug
483
-
484
- ensure
485
-
486
469
  end
@@ -53,7 +53,7 @@ class App
53
53
 
54
54
  # Set up
55
55
  #
56
- def initialize(args)
56
+ def initialize(**args)
57
57
  if args.include? '-help'
58
58
  @help = true
59
59
  return
@@ -66,6 +66,7 @@ class App
66
66
 
67
67
  wintype_idx = args.index { |a| a == WIN_TYPE_PARAM }
68
68
  raise 'missing option: -windowType' unless wintype_idx
69
+
69
70
  args.delete_at wintype_idx
70
71
  @window_type = args.delete_at(wintype_idx).to_sym
71
72
 
@@ -93,6 +94,7 @@ class App
93
94
 
94
95
  if @as_user
95
96
  raise 'Only root can do things as another user' unless JSS.superuser?
97
+
96
98
  cmd = ['su', '-l', @as_user, '-c', "#{Shellwords.escape __FILE__} #{@arg_string}"]
97
99
  exec(*cmd)
98
100
  end
@@ -134,7 +136,7 @@ This command takes all the same commandline options as jamfHelper, plus these:
134
136
  WARNING: You shouldn't run this command directly as a launchd job. Rather
135
137
  you should write a small script that runs this command, and use launchd
136
138
  to run that.
137
- ENDHELP
139
+ ENDHELP
138
140
  end # show help
139
141
 
140
142
  end # app
@@ -194,7 +194,7 @@ module Jamf
194
194
  #
195
195
  # See Jamf::APIObject#initialize
196
196
  #
197
- def initialize(args)
197
+ def initialize(**args)
198
198
  super
199
199
  general = @init_data[:general]
200
200
  @display_name = general[:display_name]
data/lib/jamf/version.rb CHANGED
@@ -27,6 +27,6 @@
27
27
  module Jamf
28
28
 
29
29
  ### The version of ruby-jss
30
- VERSION = '2.1.0b4'.freeze
30
+ VERSION = '2.1.0b5'.freeze
31
31
 
32
32
  end # module
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-jss
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0b4
4
+ version: 2.1.0b5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chris Lasell
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2022-09-15 00:00:00.000000000 Z
13
+ date: 2022-09-23 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: CFPropertyList