From 2bedeef683289b4cc5b1cb0ff4adc2a46e95d9f9 Mon Sep 17 00:00:00 2001 From: Brandon Schlueter Date: Wed, 16 Dec 2015 02:25:26 -0500 Subject: [PATCH] Join the path with File.join Hardcoding '/' as a path separator will break on systems where '\' or some other path separator is used instead. --- lib/vagrant-env/config.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/vagrant-env/config.rb b/lib/vagrant-env/config.rb index f8a79c9..cd3a515 100644 --- a/lib/vagrant-env/config.rb +++ b/lib/vagrant-env/config.rb @@ -8,7 +8,7 @@ class Config < Vagrant.plugin("2", :config) # config.env.enable __FILE__ def enable(vagrantfile = nil) if vagrantfile - load File.dirname(vagrantfile) + '/.env' + load File.join File.dirname(vagrantfile), '.env' else # The default is .env in the current directory - but that may not be # the same directory that the Vagrantfile is in