Skip to content

Commit

Permalink
Added quotes to location to handle spaces in file paths
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffpeck-intellify committed May 28, 2017
1 parent 06b75cd commit 901859f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/vagrant-hostmanager/hosts_file/updater.rb
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class << self
line_endings = "crlf"
else
hosts_location = '/etc/hosts'
copy_proc = Proc.new { `[ -w #{hosts_location} ] && cat #{file} > #{hosts_location} || sudo cp #{file} #{hosts_location}` }
copy_proc = Proc.new { `[ -w "#{hosts_location}" ] && cat "#{file}" > "#{hosts_location}" || sudo cp "#{file}" "#{hosts_location}"` }
line_endings = "lf"
end

Expand Down

0 comments on commit 901859f

Please sign in to comment.