Hello,
I'd like to script the following:
As input parameter, the script recieves a source and a destination directory.
The first file (lets say the file beeing listet first if ll-ing) in the source directoy should be copied to the dest. directory. Then some other stuff is done by the script(irrelevant).
Then the next file in source directory listing should be copied to the destination directory and some other stuff is done again.
This loopes until all files in source directory have been copied.
I am not asking for the intire script here, but just a hint, how this could be solved. My main problem is to get the filenames to variables sequencially using .sh scripting-procedures. With this filenames in a loop I may simply use cp with this fienames etc.
Probably it is quite simple, but I don't get it.
Just a hint please...
Regards,
Robert
I'd like to script the following:
As input parameter, the script recieves a source and a destination directory.
The first file (lets say the file beeing listet first if ll-ing) in the source directoy should be copied to the dest. directory. Then some other stuff is done by the script(irrelevant).
Then the next file in source directory listing should be copied to the destination directory and some other stuff is done again.
This loopes until all files in source directory have been copied.
I am not asking for the intire script here, but just a hint, how this could be solved. My main problem is to get the filenames to variables sequencially using .sh scripting-procedures. With this filenames in a loop I may simply use cp with this fienames etc.
Probably it is quite simple, but I don't get it.
Just a hint please...
Regards,
Robert