$ awk '{print "'"}'
>
-bash2-2.05b$ awk '{print "\'"}'
>
-bash2-2.05b$ awk '{print ".'"}'
>
-bash2-2.05b$ awk '{print ".\'"}'
>
How am I escaping the ' character? I need to print a statement that contains the following:
awk '/403/ && /Request/{print "perl -pi -e 's/logged/"$3" logged/g'"}'
where the output is:
perl -pi -e 's/logged/$3 logged/g'
perl -e 'print $i=pack(c5,(40*2),sqrt(7600),(unpack(c,Q)-3+1+3+3-7),oct(104),10,oct(101));'
>
-bash2-2.05b$ awk '{print "\'"}'
>
-bash2-2.05b$ awk '{print ".'"}'
>
-bash2-2.05b$ awk '{print ".\'"}'
>
How am I escaping the ' character? I need to print a statement that contains the following:
awk '/403/ && /Request/{print "perl -pi -e 's/logged/"$3" logged/g'"}'
where the output is:
perl -pi -e 's/logged/$3 logged/g'
perl -e 'print $i=pack(c5,(40*2),sqrt(7600),(unpack(c,Q)-3+1+3+3-7),oct(104),10,oct(101));'