Skip to content

The underlying search method depends on the board, but most will search for text in the pin name and title.

Usage

pin_search(board, search = NULL, ...)

Arguments

board

A pin board, created by board_folder(), board_connect(), board_url() or another board_ function.

A string to search for in pin name and title. Use NULL to return all pins.

...

Additional arguments passed on to methods.

Value

A data frame that summarises the metadata for each pin. Key attributes (name, type, description, created, and file_size) are pulled out into columns; everything else can be found in the meta list-column.

Examples

board <- board_temp()

board %>% pin_write(1:5, "x", title = "Some numbers")
#> Guessing `type = 'rds'`
#> Creating new version '20241213T233102Z-0050f'
#> Writing to pin 'x'
board %>% pin_write(letters[c(1, 5, 10, 15, 21)], "y", title = "My favourite letters")
#> Guessing `type = 'rds'`
#> Creating new version '20241213T233102Z-e4901'
#> Writing to pin 'y'
board %>% pin_write(runif(20), "z", title = "Random numbers")
#> Guessing `type = 'rds'`
#> Creating new version '20241213T233102Z-a6d81'
#> Writing to pin 'z'

board %>% pin_search()
#> # A tibble: 3 × 6
#>   name  type  title               created             file_size meta      
#>   <chr> <chr> <chr>               <dttm>              <fs::byt> <list>    
#> 1 x     rds   Some numbers        2024-12-13 23:31:02        50 <pins_met>
#> 2 y     rds   My favourite lette… 2024-12-13 23:31:02        58 <pins_met>
#> 3 z     rds   Random numbers      2024-12-13 23:31:02       166 <pins_met>
board %>% pin_search("number")
#> # A tibble: 2 × 6
#>   name  type  title          created               file_size meta      
#>   <chr> <chr> <chr>          <dttm>              <fs::bytes> <list>    
#> 1 x     rds   Some numbers   2024-12-13 23:31:02          50 <pins_met>
#> 2 z     rds   Random numbers 2024-12-13 23:31:02         166 <pins_met>
board %>% pin_search("letters")
#> # A tibble: 1 × 6
#>   name  type  title               created             file_size meta      
#>   <chr> <chr> <chr>               <dttm>              <fs::byt> <list>    
#> 1 y     rds   My favourite lette… 2024-12-13 23:31:02        58 <pins_met>