Exception: ElasticBeans::Command::SetEnv::MissingValueError

Inherits:
Error
  • Object
show all
Defined in:
lib/elastic_beans/command/set_env.rb

Instance Method Summary collapse

Constructor Details

#initialize(key:) ⇒ MissingValueError

Returns a new instance of MissingValueError.



86
87
88
# File 'lib/elastic_beans/command/set_env.rb', line 86

def initialize(key:)
  @key = key
end

Instance Method Details

#messageObject



90
91
92
93
94
95
# File 'lib/elastic_beans/command/set_env.rb', line 90

def message
  "Missing value for key '#{@key}'. " \
  "Should it be part of the previous value? " \
  "You may need to quote the key/value pair (e.g. `#{command_as_string("setenv 'MYVAR=myvalue, myvalue2'")}`) " \
  "or escape a space (e.g. `#{command_as_string("setenv MYVAR=myvalue,\\ myvalue2")}`)."
end