gnu-sed Questions
5
Solved
I have the following bash script which repeats for each image found. It needs to iterated over all html, css and js files, and replace all occurrences of an image within that file.
for image in a...
1
I wrote the following command
echo -en 'uno\ndue\n' | sed -E 's/^.*(uno|$)/\1/'
expecting the following output
uno
This is indeed the case with my GNU Sed 4.8.
However, I've verified that BSD Se...
1
Using GNU sed (with the -r flag for clarity), the following two substitutions on the input string ab give the same result:
s/(.)(.)|(.)(.)$/\2\1\3\4/
and
s/(.)(.)$|(.)(.)/\1\2\4\3/
both give ...
1
Solved
Running Fedora 25 server edition. sed --version gives me sed (GNU sed) 4.2.2 along with the usual copyright and contact info. I've create a text file sudo vi ./potential_sed_bug. Vi shows the conte...
1
© 2022 - 2025 — McMap. All rights reserved.