Search Results

Search: Posts Made By: SirHenry1
5,811
Posted By Corona688
The only way I've been able to make awk work...
The only way I've been able to make awk work reliably from Windows CMD is to put the code into a text file and run it with -f.

/[^\t]/

awk -f mycode.txt filename
2,005
Posted By bakunin
You need the "\(...\)" device for this. This way...
You need the "\(...\)" device for this. This way you can replicate parts of the matched regexp in the substitution:

sed 's/0\([0-9]\)/\1/'

will replace any "0" followed by a digit with this...
2,005
Posted By Corona688
sed doesn't work that way. putting [0-9] in the...
sed doesn't work that way. putting [0-9] in the output pattern will not cause it to substitute any of the input.

To do that, you want a backreference.

sed 's#0\([0-9]\)/#\1/#'
Showing results 1 to 3 of 3

 
All times are GMT -4. The time now is 07:59 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy