| 1 |
% Generated by roxygen2: do not edit by hand |
| 2 |
% Please edit documentation in R/upload.R |
| 3 |
\name{curl_upload} |
| 4 |
\alias{curl_upload} |
| 5 |
\title{Upload a File} |
| 6 |
\usage{ |
| 7 |
curl_upload(file, url, verbose = TRUE, reuse = TRUE, ...) |
| 8 |
} |
| 9 |
\arguments{ |
| 10 |
\item{file}{connection object or path to an existing file on disk} |
| 11 |
|
| 12 |
\item{url}{where to upload, should start with e.g. \verb{ftp://}} |
| 13 |
|
| 14 |
\item{verbose}{emit some progress output} |
| 15 |
|
| 16 |
\item{reuse}{try to keep alive and recycle connections when possible} |
| 17 |
|
| 18 |
\item{...}{other arguments passed to \code{\link[=handle_setopt]{handle_setopt()}}, for |
| 19 |
example a \code{username} and \code{password}.} |
| 20 |
} |
| 21 |
\description{ |
| 22 |
Upload a file to an \verb{http://}, \verb{ftp://}, or \verb{sftp://} (ssh) |
| 23 |
server. Uploading to HTTP means performing an \verb{HTTP PUT} on that URL. |
| 24 |
Be aware that sftp is only available for libcurl clients built with libssh2. |
| 25 |
} |
| 26 |
\examples{ |
| 27 |
\dontrun{# Upload package to winbuilder: |
| 28 |
curl_upload('mypkg_1.3.tar.gz', 'ftp://win-builder.r-project.org/R-devel/') |
| 29 |
} |
| 30 |
} |