From bafb572b701129cabde8e6b07b22a86b2c41a2f1 Mon Sep 17 00:00:00 2001 From: Brice Figureau Date: Sun, 12 Dec 2010 18:19:19 +0100 Subject: [PATCH] More permissive sed call on BSD hosts to prevent errors when cleaning nfs Gnu sed -i option doesn't support a space between the option and the backup extension. On BSD hosts running GNU sed (for instance OSX with Macports), it cleaning nfs shares couldn't happen. Signed-off-by: Brice Figureau --- lib/vagrant/hosts/bsd.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/vagrant/hosts/bsd.rb b/lib/vagrant/hosts/bsd.rb index ef465fae1..ac6b17fdb 100644 --- a/lib/vagrant/hosts/bsd.rb +++ b/lib/vagrant/hosts/bsd.rb @@ -42,7 +42,7 @@ module Vagrant if $?.to_i == 0 # Use sed to just strip out the block of code which was inserted # by Vagrant - system("sudo sed -e '/^# VAGRANT-BEGIN: #{env.vm.uuid}/,/^# VAGRANT-END: #{env.vm.uuid}/ d' -i bak /etc/exports") + system("sudo sed -e '/^# VAGRANT-BEGIN: #{env.vm.uuid}/,/^# VAGRANT-END: #{env.vm.uuid}/ d' -ibak /etc/exports") end end end