This is a lower-level interface than
you can use to pin any file, as opposed to any R object. The path returned
pin_download() is a read-only path to a cached file: you should never
attempt to modify this file.
pin_download(board, name, version = NULL, hash = NULL, ...) pin_upload( board, paths, name = NULL, title = NULL, description = NULL, metadata = NULL, ... )
Retrieve a specific version of a pin. Use
find out which versions are available and when they were created.
Specify a hash to verify that you get exactly the dataset that
you expect. You can find the hash of an existing pin by looking for
Additional arguments passed on to methods for a specific board.
A character vector of file paths to upload to
A title for the pin; most important for shared boards so that others can understand what the pin contains. If omitted, a brief description of the contents will be automatically generated.
A detailed description of the pin contents.
A list containing additional metadata to store with the pin.
When retrieving the pin, this will be stored in the
user key, to
avoid potential clashes with the metadata that pins itself uses.
pin_download() returns a character vector of file paths;
pin_upload() returns the fully qualified name of the new pin, invisibly.
board <- board_temp() board %>% pin_upload(system.file("CITATION")) #> Guessing `name = 'CITATION'` #> Creating new version '20211004T114924Z-dec01' path <- board %>% pin_download("CITATION") path #>  "/tmp/RtmpOFHnBR/pins-346bad87710/CITATION/20211004T114924Z-dec01/CITATION" readLines(path)[1:5] #>  "bibentry(\"Manual\"," #>  " title = \"R: A Language and Environment for Statistical Computing\"," #>  " author = person(\"R Core Team\")," #>  " organization = \"R Foundation for Statistical Computing\"," #>  " address = \"Vienna, Austria\","