mirror of
https://github.com/servalproject/serval-dna.git
synced 2024-12-21 14:07:53 +00:00
Issue #25, fix sed(1) statement for Mac OS X
Seems that OS X sed(1) does not support the compound '{cmd;cmd}' syntax in the same way as GNU sed(1).
This commit is contained in:
parent
6954325b04
commit
7ee5266998
@ -227,7 +227,7 @@ rhizome_http_server_started() {
|
||||
get_rhizome_server_port() {
|
||||
local _var="$1"
|
||||
local _logvar=LOG${2#+}
|
||||
local _port=$($SED -n -e '/.*RHIZOME HTTP SERVER.*START/{s/.*port=\([0-9]\{1,\}\).*/\1/p;q}' "${!_logvar}")
|
||||
local _port=$($SED -n -e '/RHIZOME HTTP SERVER.*START/s/.*port=\([0-9]\{1,\}\).*/\1/p' "${!_logvar}" | $SED -n '$p')
|
||||
assert --message="instance $2 Rhizome HTTP server port number is known" [ -n "$_port" ]
|
||||
if [ -n "$_var" ]; then
|
||||
eval "$_var=\$_port"
|
||||
|
Loading…
Reference in New Issue
Block a user