Closed coolbrg closed 8 years ago
Currently, we are using two formats in Vagrantfile for setting configurations
if
if ENV.has_key?('SUB_USERNAME') && ENV.has_key?('SUB_PASSWORD') config.registration.username = ENV['SUB_USERNAME'] config.registration.password = ENV['SUB_PASSWORD'] end
ENV['PROXY'] ? (config.registration.proxy = PROXY = ENV['PROXY']) : PROXY = ''
First one gives more readability while second option allow to achieve minimal Vagrantfile goal.
Any thoughts which should be used?
NOTE: ENV['PROXY'] should be ENV.key?('PROXY') (Should be fix as part of this issue fix)
ENV['PROXY']
ENV.key?('PROXY')
@budhrg Let's go with readability, one liner approach looks bit more crypt. @LalatenduMohanty @hferentschik WDYT?
+1 For readability.
+1 For readability
Currently, we are using two formats in Vagrantfile for setting configurations
if
block asFirst one gives more readability while second option allow to achieve minimal Vagrantfile goal.
Any thoughts which should be used?
NOTE:
ENV['PROXY']
should beENV.key?('PROXY')
(Should be fix as part of this issue fix)