From fb70300645448ea8afca124848bfa1eba774b5aa Mon Sep 17 00:00:00 2001 From: juliasilge Date: Fri, 13 Dec 2024 23:31:35 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20rstudio/?= =?UTF-8?q?pins-r@669ab4e4e1f5c345d0a70260b43cbf23fd1d39f3=20=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- dev/articles/customize-pins-metadata.html | 2 +- dev/articles/managing-custom-formats.html | 4 +-- dev/articles/pins-update.html | 12 ++++---- dev/articles/pins.html | 34 +++++++++++------------ dev/articles/using-board-url.html | 16 +++++------ dev/news/index.html | 1 + dev/pkgdown.yml | 2 +- dev/reference/board_register.html | 2 +- dev/reference/board_s3.html | 17 +++++++----- dev/reference/legacy_local.html | 2 +- dev/reference/pin.html | 2 +- dev/reference/pin_browse.html | 8 +++--- dev/reference/pin_delete.html | 6 ++-- dev/reference/pin_download.html | 4 +-- dev/reference/pin_fetch.html | 4 +-- dev/reference/pin_find.html | 2 +- dev/reference/pin_info.html | 8 +++--- dev/reference/pin_list.html | 6 ++-- dev/reference/pin_meta.html | 18 ++++++------ dev/reference/pin_read.html | 16 +++++------ dev/reference/pin_search.html | 18 ++++++------ dev/reference/pin_versions.html | 12 ++++---- dev/reference/write_board_manifest.html | 10 +++---- dev/search.json | 2 +- 24 files changed, 106 insertions(+), 102 deletions(-) diff --git a/dev/articles/customize-pins-metadata.html b/dev/articles/customize-pins-metadata.html index 1e8cbb10..3185bfab 100644 --- a/dev/articles/customize-pins-metadata.html +++ b/dev/articles/customize-pins-metadata.html @@ -138,7 +138,7 @@

A function to store factors
 ten_letters <- factor(sample(letters, size = 10), levels = letters)
 board %>% pin_write_factor_json(ten_letters, "letters-as-json")
-#> Creating new version '20241213T221813Z-099e2'
+#> Creating new version '20241213T233106Z-099e2'
 #> Writing to pin 'letters-as-json'

A function to read factors diff --git a/dev/articles/managing-custom-formats.html b/dev/articles/managing-custom-formats.html index c09ffda6..301425f3 100644 --- a/dev/articles/managing-custom-formats.html +++ b/dev/articles/managing-custom-formats.html @@ -133,7 +133,7 @@

Upload a single filearrow::write_feather(mtcars, path, compression = "uncompressed") pin_upload(board, paths = path, name = pin_name) -#> Creating new version '20241213T221815Z-a863e'

+#> Creating new version '20241213T233109Z-a863e'

Reading from the downloaded pin is straightforward; pin_download() returns a local path that can be piped to arrow::read_feather():

@@ -173,7 +173,7 @@

Function to manage uploadingpin_write():

 pin_upload_arrow(board, x = mtcars, name = "mtcars-arrow2")
-#> Creating new version '20241213T221815Z-a863e'
+#> Creating new version '20241213T233109Z-a863e'

As before, you can pipe the result of pin_download() to your reader function:

diff --git a/dev/articles/pins-update.html b/dev/articles/pins-update.html
index 2de6607d..7542c0b5 100644
--- a/dev/articles/pins-update.html
+++ b/dev/articles/pins-update.html
@@ -140,7 +140,7 @@ 

Examples pin_write(board, head(mtcars), "mtcars") #> Guessing `type = 'rds'` -#> Creating new version '20241213T221819Z-fe62f' +#> Creating new version '20241213T233113Z-fe62f' #> Writing to pin 'mtcars' pin_read(board, "mtcars") #> mpg cyl disp hp drat wt qsec vs am gear carb @@ -179,7 +179,7 @@

Pinning filespin(path, "alphabet", board = "vignette") pin_get("alphabet", board = "vignette") -#> [1] "/tmp/RtmpqVP5iU/file1d327e66ee78/alphabet/file1d32294d330e"

+#> [1] "/tmp/Rtmp4tONlv/file1d8b7c45cbe/alphabet/file1d8b4c74cfa5"

pins 1.0.0 clearly separates the two cases of pin an object and pinning a file, so here instead of pin_write() and pin_read() you need to pin_upload() and @@ -187,9 +187,9 @@

Pinning files
 # Modern API
 board %>% pin_upload(path, "alphabet")
-#> Creating new version '20241213T221820Z-ee580'
+#> Creating new version '20241213T233114Z-ee580'
 board %>% pin_download("alphabet")
-#> [1] "~/.local/share/pins/alphabet/20241213T221820Z-ee580/file1d32294d330e"
+#> [1] "~/.local/share/pins/alphabet/20241213T233114Z-ee580/file1d8b4c74cfa5"

Pinning a url @@ -201,7 +201,7 @@

Pinning a urlbase <- "https://raw.githubusercontent.com/rstudio/pins-r/main/tests/testthat/" (pin(paste0(base, "pin-files/first.txt"), board = "vignette")) -#> [1] "/tmp/RtmpqVP5iU/file1d327e66ee78/first/first.txt"

+#> [1] "/tmp/Rtmp4tONlv/file1d8b7c45cbe/first/first.txt"

This now needs to be made explicit with the new board_url(), and since this returns a path, not a file, you need to use pin_download():

@@ -235,7 +235,7 @@

Implicit board board %>% pin_write(data.frame(x = 1:3), "test-data") #> Guessing `type = 'rds'` -#> Creating new version '20241213T221820Z-66fa6' +#> Creating new version '20241213T233114Z-66fa6' #> Writing to pin 'test-data' board %>% pin_read("test-data") #> x diff --git a/dev/articles/pins.html b/dev/articles/pins.html index 2c2b7e7d..73b0ea00 100644 --- a/dev/articles/pins.html +++ b/dev/articles/pins.html @@ -120,7 +120,7 @@

Reading and writing datamtcars <- tibble::as_tibble(mtcars) board %>% pin_write(mtcars, "mtcars") #> Guessing `type = 'rds'` -#> Creating new version '20241213T221822Z-e5d8a' +#> Creating new version '20241213T233116Z-e5d8a' #> Writing to pin 'mtcars'

The first argument is the object to save (usually a data frame, but it can be any R object), and the second argument gives the “name” of the @@ -219,14 +219,14 @@

Metadata#> $ description: NULL #> $ tags : NULL #> $ urls : NULL -#> $ created : POSIXct[1:1], format: "2024-12-13 22:18:22" +#> $ created : POSIXct[1:1], format: "2024-12-13 23:31:16" #> $ api_version: int 1 #> $ user : list() #> $ name : chr "mtcars" #> $ local :List of 3 -#> ..$ dir : 'fs_path' chr "/tmp/RtmptcluLr/pins-1d78e900bc0/mtcars/20241213T221822Z-e5d8a" +#> ..$ dir : 'fs_path' chr "/tmp/RtmpPGvAfv/pins-1dd1768eb3e7/mtcars/20241213T233116Z-e5d8a" #> ..$ url : NULL -#> ..$ version: chr "20241213T221822Z-e5d8a" +#> ..$ version: chr "20241213T233116Z-e5d8a"

This shows you the metadata that’s generated by default. This includes: