Saturday, 24 August 2013

BASH: sed -e not allowing my variable

BASH: sed -e not allowing my variable

My line variable is not being accepted by my sed command :(
linenumber=`grep -n "$player" "$outputfile" | sed 's/^\([0-9]\+\):.*$/\1/'`
sed -e "'${linenumber}'s/2013-08-25/test/"
my output is:
sed: -e expression #1, char 1: unknown command: `''
Any idea?

No comments:

Post a Comment