node-ftp icon indicating copy to clipboard operation
node-ftp copied to clipboard

Can we move file from one folder in FTP to another Folder?

Open dsouzamanish opened this issue 8 years ago • 1 comments

Lets Say i have a filenameA in /files/ folder. After processing this file i want to move it to /processed folder.

Do i have to download-delete-upload to new folder? Is there an endpoint for the same?

dsouzamanish avatar Jul 28 '17 07:07 dsouzamanish

You can use the rename() function, worked for me


conn.rename(oldPath, newPath, (err)=> {
    console.log(err)
})

thiagohagy avatar Feb 12 '19 18:02 thiagohagy