Class: Vagrant::Util::SafeEnv

Inherits:
Object
  • Object
show all
Defined in:
lib/vagrant/util/safe_env.rb

Class Method Summary collapse

Class Method Details

.change_envObject

This yields an environment hash to change and catches any issues while changing the environment variables and raises a helpful error to end users.



10
11
12
13
14
# File 'lib/vagrant/util/safe_env.rb', line 10

def self.change_env
  yield ENV
rescue Errno::EINVAL
  raise Errors::EnvInval
end