Copies the file/dir to the remote server from the local server. If the dst
is a folder it will copy the file into that folder.
Usage
remote.copy.to(host, src, dst, options = NULL, delete = FALSE, stderr = FALSE)
Arguments
- host
host structure to execute command on
- src
local file/dir to copy
- dst
remote file/dir to copy to
- options
additional arguments to be passed to rsync command
- delete
in case of local dir should all non-existent files be removed
- stderr
should stderr be returned as well.
Value
output of command executed
Examples
if (FALSE) { # \dontrun{
host <- list(name='geo.bu.edu', user='kooper', tunnel='/tmp/geo.tunnel')
remote.copy.to(host, '/tmp/kooper', '/tmp/kooper', delete=TRUE)
} # }