Skip to content

Commit

Permalink
Improve documentation about deleting pin versions (#773)
Browse files Browse the repository at this point in the history
* Improve documentation about deleting pin versions

* Update NEWS
  • Loading branch information
juliasilge authored Aug 31, 2023
1 parent 1d15a31 commit 917303b
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 3 deletions.
3 changes: 3 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@
* Fixed how dots are checked in `pin_write()` to make user-facing messages more
clear (#770).

* Improved documentation about Connect caches (#771) and deleting pin versions (#773).

* Added `board_deparse` for `board_url()` (#774).


# pins 1.2.1

* New environment variable `PINS_CACHE_DIR` controls the location of the
Expand Down
2 changes: 1 addition & 1 deletion R/pin_versions.R
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ pin_version_delete.pins_board <- function(board, name, version, ...) {
#' @rdname pin_versions
#' @param n,days Pick one of `n` or `days` to choose how many versions to
#' keep. `n = 3` will keep the last three versions, `days = 14` will
#' keep all the versions in the 14 days. Regardless of what values you
#' keep all the versions created in the 14 days. Regardless of what values you
#' set, `pin_versions_prune()` will never delete the most recent version.
pin_versions_prune <- function(board, name, n = NULL, days = NULL, ...) {
versions <- pin_versions(board, name)
Expand Down
2 changes: 1 addition & 1 deletion man/pin_versions.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion vignettes/pins.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ You can list all the available versions with `pin_versions()`:
board2 %>% pin_versions("x")
```

(Pins does not currently provide any tool to remove old versions, but this is likely to be implemented in the future.)
You can delete a specific older version with `pin_version_delete()` or sets of older versions with `pin_versions_prune()`.

By default, `pin_read()` will return the most recent version:

Expand Down

0 comments on commit 917303b

Please sign in to comment.