Dear All,
I need you help, I have a file
allfile_dump.txt
\370380CoverPage124007001.pdf
\370381CoverPage124007002.pdf
\370382CoverPage124007003.pdf
\370383CoverPage124007004.pdf
\370384CoverPage124007005.pdf
\370385CoverPage124007006.pdf
\370386CoverPage124007007.pdf
\370387CoverPage124007008.pdf
I want to replce the content as
below
smbclient -A $LOGIN_SMB $archiveroot << !!!
del "370380CoverPage124007001.pdf"
del "370386CoverPage124007007.pdf"
del "370387CoverPage124007008.pdf"
By what criterion do entries in allfile_dump.txt
get used or not ?
1 Like
we will keep allfile_dump.txt for audit purpose but if it possible to append same file its ok.
this is how i am populating the file
cat $UNXLOG/filelist_dump.txt | grep ".pdf"| grep -v directory| cut -d")" -f2-|cut -d" " -f2- > $UNXLOG/allfile_dump.txt
Please suggest
I mean, why do:
\370381CoverPage124007002.pdf
\370382CoverPage124007003.pdf
\370383CoverPage124007004.pdf
\370384CoverPage124007005.pdf
\370385CoverPage124007006.pdf
not get used?
1 Like
while deleting the files from shared drive on network it need the specified format.
it should be del "filename"
thanks
I mean why do
\370380CoverPage124007001.pdf
\370386CoverPage124007007.pdf
\370387CoverPage124007008.pdf
get used and why do:
\370381CoverPage124007002.pdf
\370382CoverPage124007003.pdf
\370383CoverPage124007004.pdf
\370384CoverPage124007005.pdf
\370385CoverPage124007006.pdf
not get used? What is the criterion..
1 Like
scrutinizer:
I mean why do
\370380CoverPage124007001.pdf
\370386CoverPage124007007.pdf
\370387CoverPage124007008.pdf
get used and why do:
\370381CoverPage124007002.pdf
\370382CoverPage124007003.pdf
\370383CoverPage124007004.pdf
\370384CoverPage124007005.pdf
\370385CoverPage124007006.pdf
not get used? What is the criterion..
Ohh sorry for confusion. it was just sample What i want is replace all line in file with del "linevalue"
del "DRI10566_124007001.pdf"
del "DRI10566_124007002.pdf"
del "DRI10566_124007003.pdf"
del "DRI10566_124007004.pdf"
del "DRI10566_124007005.pdf"
del "DRI10566_124007006.pdf"
del "DRI10566_124007007.pdf"
del "DRI10566_124007008.pdf"
Do you mean like this?
sed 's/^\\/del "/; s/$/"/' file
1 Like
yes perfect.. thanks for quick reply