I have a list file called demo.lst which has a filename demo_one_two_20210203_XM3304.csv. I am looking for a one line command or multiple commands in single line which will read the filename from the list file and move it to a destination by renaming it as shown below. List File :demo.lst Contents of List File :demo_one_two_20210203_XM3304.csv Source File Name :demo_one_two_20210203_XM3304.csv Target Location: \incc\demo\target Target File : demo_one_two_20210203.csv I am using xargs -a demo.lst mv -t incc\demo\target; which is moving the file as is without trimming everythin after _XM. I want to trim everything after _XM while moving the file and append it with .csv
awk
cut
xargs
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)