node-scp-async icon indicating copy to clipboard operation
node-scp-async copied to clipboard

How to remove a file on remote server

Open smitterer opened this issue 2 years ago • 1 comments

Hi,

how would I remove one or multiple file(s) from a remote folder?

Is this possible with this node?

Thanks

smitterer avatar Sep 19 '22 12:09 smitterer

yes, the library does support that. Use these:

  • unlink(remotePath: string) to remove a file
  • rmdir(remotePath: string) to remove a folder

These API are missing from README, I'm gonna update it

maitrungduc1410 avatar Sep 19 '22 14:09 maitrungduc1410