Jasper sed "s/WPT001/$WPTN/" $LOC/loc2test.gpx > $LOC/loc2test_sed.gpx
gave the right result, however one weird thing is that even with the ../g" global switch it changed all the "WPT001"'s rather than just the first instance ? (output): <wpt lat="-43.571090000" lon="172.689703333"> <ele>-2.800000</ele> <time>2008-08-06T23:57:50Z</time> <name>WP1450</name> <cmt>WP1450</cmt> <desc>WP1450</desc> <fix>dgps</fix> <sat>9</sat> many thanks dave 2008/8/8 Dave G <[EMAIL PROTECTED]> > Jasper > > I've previously tried double quoting "$WPTN" ... no luck ... somewhere > else? > > 2008/8/8 Jasper Bryant-Greene <[EMAIL PROTECTED]> > > On Fri, 2008-08-08 at 14:15 +1200, Dave G wrote: >> > sed 's/WPT001/$WPTN/' $LOC/$WPTF > $GCF/$WPTY >> >> Use double quotes here if you want the variable to be expanded. >> >> -Jasper >> >> >
