remote file deletion using xargs

From: shihab (shihabvk_at_gmail.com)
Date: 09/29/05


Date: 29 Sep 2005 04:42:10 -0700

Hi,
Please help me...
I am creating a string of filenames with absolute path and deleting
those files situated in the remote server using ssh .. but it doesnot
work..
Can anyone help me...
here is my code

for FileName in ${myDire}
do
Tmp=`basename $FileName`
DelFiles="${DelFiles} "${SourceDirectory}/${Tmp}
done
#DelFiles contain files to be deleted with abolute path

ssh USer/Pwd@Domain echo ${DelFiles} | xargs rm

This statement gives 0 as the return value , but not deleting any of
those files

Thanks in advance
Shihab



Relevant Pages

  • Re: remote file deletion using xargs
    ... > I am creating a string of filenames with absolute path and deleting ... > for FileName in $ ...
    (comp.unix.shell)
  • Re: lock on filename for XmlDocument.Save?
    ... sometimes absolute path and sometimes relative path. ... XmlDocument.Save with a filename attempts to open the file in Create mode for Writing with only Read sharing. ... if you don't really care that the second simultaneous Save is going to destroy the data from the first Save, you could just do a lock the XmlDocument.Save function call, which will enforce only one save at a time, or you could do a bit more complicated logic if you do care that you are overwriting an existing file, which will happen once the first Savecompletes. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: going crazy - need help with INCLUDETEXT!!!
    ... Deleting the filepaths doesn't change where Word looks for the files - the only way to do that is to provide a new path. ... I suspect this is something to do with that square character you referred to acting as a bookmark reference of some kind. ... Word's help file explains the INCLUDTEXT field's usage pretty well. ... Simply changing the filename without updating the field isn't enough. ...
    (microsoft.public.word.pagelayout)
  • Re: How can file be permanently deleted but still recoverable
    ... deleting the file would result in the last ... If you knew the full filename, ... > So your chances of successfully recovering this file are decent ... your chances are probably very poor by now. ...
    (microsoft.public.windowsxp.general)
  • Re: using getcwd
    ... :: Dazza:: wrote: ... > the absolute path? ... If your file maininclude.php has the code for opening/reading links.txt ... Then the $filename must be includes/links.txt, as that is the relative path ...
    (alt.php)