Improvements in env.rb