From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <0ce4afcf62f74dc513a6aa1941a39d95@quintile.net> From: "Steve Simon" Date: Tue, 10 Aug 2010 09:37:18 +0100 To: 9fans@9fans.net In-Reply-To: <09DB2D65-A18A-493E-9886-2D5D3334F460@corpus-callosum.com> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Subject: Re: [9fans] regexp metacharacter difficulty inside grap Topicbox-Message-UUID: 4663721e-ead6-11e9-9d60-3106f5b1d025 > if "$2" == "(Yo" then { > print sprintf("Yo was %f", yo) > yo = sh { echo $3 | sed 's/\)#//' } > print sprintf("Yo is %f", yo) > } Not sure I get the twists and turns of your shell, which one are you using as I assume the subtle details are important here - is it bash? also who's grap is this, is it plan9's or some unix/linux? My take on the same parsing problem is: larch% echo '(Yo 4.9524)' | awk '{print $2+0}' 4.9524 I don't know if this helps (probably not). -Steve