Use BSD's 'sed' regexp on MacOSX
VirtualBox scripts tested well only with GNU version of the 'sed', but MacOSX systems without custom brew-installed packages contain BSD's version of the sed. This commit fixes regexp to use both versions. Change-Id: I058cac4eb9c2beefffc20ad05a47bc1d8ed2169d Closes-Bug: #1537822
This commit is contained in:
parent
291c8c4319
commit
ddeb2f866a
|
@ -19,7 +19,7 @@
|
|||
source ./functions/shell.sh
|
||||
|
||||
get_hostonly_interfaces() {
|
||||
local ifaces=`execute VBoxManage list hostonlyifs | egrep '^Name' | sed 's/^Name\:\s*//' | uniq | tr "\\n" ","`
|
||||
local ifaces=`execute VBoxManage list hostonlyifs | egrep '^Name' | sed 's/^Name\:[ \t]*//' | uniq | tr "\\n" ","`
|
||||
echo -e "${ifaces}"
|
||||
}
|
||||
|
||||
|
@ -33,7 +33,7 @@ get_fuel_ifaces() {
|
|||
fuel_networks+="$fuel_network "
|
||||
done
|
||||
for ip in $fuel_networks; do
|
||||
fuel_iface=`execute VBoxManage list hostonlyifs | egrep -B3 $ip | egrep '^Name' | sed 's/^Name\:\s*//' | uniq | tr "\\n" ","`
|
||||
fuel_iface=`execute VBoxManage list hostonlyifs | egrep -B3 $ip | egrep '^Name' | sed 's/^Name\:[ \t]*//' | uniq | tr "\\n" ","`
|
||||
fuel_ifaces+="$fuel_iface"
|
||||
done
|
||||
echo $fuel_ifaces
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
source ./functions/shell.sh
|
||||
|
||||
get_vm_base_path() {
|
||||
echo `execute VBoxManage list systemproperties | egrep '^Default machine folder' | sed 's/^Default machine folder\:\s*//'`
|
||||
echo `execute VBoxManage list systemproperties | egrep '^Default machine folder' | sed 's/^Default machine folder\:[ \t]*//'`
|
||||
}
|
||||
|
||||
get_vms_running() {
|
||||
|
|
Loading…
Reference in New Issue