Hi.

I am using lftp (to an SFTP-server) to upload files from our system to
further processing at a collaborator. The collaborator prescribes
uploading the files with the extension "tmp", and the altering the
extension after a successful upload (They say, they do this to avoid touching
files, which are currently being uploaded).

I was trying to script a solution for this purely in lftp, but I have
not been able to find an easy way of renaming the files. After i mput
the lot (all called *.tmp), i would like to rename them all from
filename.tmp to filename.xml (as we are only uploading xml-files).

Currently I have solved this by a bash script, which uploads and the
renames every file one by one. This causes the opening of a connection
for every file we wish to transfer though, at least as far as I know.

Do you have any suggestions to how I could get lftp to rename the
files, once they are uploaded?


Best regards

Gregers Petersen, Denmark

Reply via email to