I would like some advice on this script.
I'm trying to use sed
(I didn't manage it with rename
) to change a file that contains lines of the format (my test file name is sedtest
):
COPY W:\Interfaces\Payments\Tameia\Unprocessed\X151008\E*.*
(that's not the only content of the file).
My goal is to replace the 151008
date part with a different date, I've tried to come up with a solution in sed
using this:
sed -i -e "s/Unprocessed\X.*/Unprocessed\X'BLABLA'/" sedtest
but it doesnt seem to work, the line remains unchanged, it's like it doesn't recognize the pattern because of the \
. I've tried some alternative delimiters like #
, but to no avail.
Thanks in advance for any advice.