Find the answer to your Linux question:
Results 1 to 4 of 4
I need to write a shellscript, the details of which are given below. Require help to write the code. I have a folder named original, and a folder named server. ...
  1. #1
    Just Joined!
    Join Date
    Jun 2009
    Posts
    2

    copying of directory

    I need to write a shellscript, the details of which are given below. Require help to write the code.

    I have a folder named original, and a folder named server.
    They have almost the same files, but original and server may have files that may be present in one but absent in another.
    I want to write a script to copy missing files from server to folder original, but I DO NOT want to overwrite existing files even if there is a date mismatch.

  2. #2
    Just Joined!
    Join Date
    Jun 2009
    Location
    Bangalore
    Posts
    3
    U can try by tar those directories.

  3. #3
    Trusted Penguin Roxoff's Avatar
    Join Date
    Aug 2005
    Location
    Nottingham, England
    Posts
    3,393
    I think for this task you should read the man page for the 'cp' command. Unfortunately this seems to be a homework question, and it's against the rules to post homework questions.
    Linux user #126863 - see http://linuxcounter.net/

  4. #4
    Just Joined!
    Join Date
    Jun 2009
    Posts
    2
    its not a homework prob, but its a task i got to do, I have a script to update , but files mostly get overwritten by the updated file, here what I want to do is to skip the files or duplicate files.
    help requested.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...