2
votes
2answers
290 views

non-case-sensitive sed - OpenWrt

the input would be like this in a file: <sCripT and the parsing looks like this: sed -i "s/<script//g" SOMETHING.html the "/gi" is not good, because OpenWrt doesn't knows it (busybox..): ...
8
votes
3answers
3k views

Zero-fill numbers to 2 digits with sed

Input: 201103 1 /mnt/hdd/PUB/SOMETHING 201102 7 /mnt/hdd/PUB/SOMETH ING 201103 11 /mnt/hdd/PUB/SO METHING 201104 3 /mnt/hdd/PUB/SOMET HING 201106 1 /mnt/hdd/PUB/SOMETHI NG Desired output: 201103 ...