Class: FluentCommandBuilder::SecurityOSX::V108::UnlockKeychain

Inherits:
CommandBase
  • Object
show all
Defined in:
lib/fluent_command_builder/command_builders/security_osx_108.rb

Instance Method Summary collapse

Methods inherited from CommandBase

#configure!, #execute!, #to_s

Constructor Details

#initialize(underlying_builder) ⇒ UnlockKeychain

Returns a new instance of UnlockKeychain.



165
166
167
168
# File 'lib/fluent_command_builder/command_builders/security_osx_108.rb', line 165

def initialize(underlying_builder)
  super underlying_builder
  @b.append ' unlock-keychain'
end

Instance Method Details

#keychain(keychain) {|@b| ... } ⇒ Object

Yields:

  • (@b)


179
180
181
182
183
# File 'lib/fluent_command_builder/command_builders/security_osx_108.rb', line 179

def keychain(keychain)
  @b.append " #{@b.format keychain}"
  yield @b if block_given?
  self
end

#no_password {|@b| ... } ⇒ Object

Yields:

  • (@b)


169
170
171
172
173
# File 'lib/fluent_command_builder/command_builders/security_osx_108.rb', line 169

def no_password
  @b.append ' -u'
  yield @b if block_given?
  self
end

#password(password) {|@b| ... } ⇒ Object

Yields:

  • (@b)


174
175
176
177
178
# File 'lib/fluent_command_builder/command_builders/security_osx_108.rb', line 174

def password(password)
  @b.append " -p #{@b.format_password password}"
  yield @b if block_given?
  self
end