Skip to contents

Fetches from each source's recorded origin and fast-forwards to it — never a hard reset, so a source that has locally diverged from its origin fails loudly (reported as status = "error" in the returned data frame) instead of silently losing anything. A local source, or one imported with subdir (its history/tags weren't preserved on import, so there's nothing to fast-forward against), always reports status = "not-updatable" — informational, not an error. There's no separate lockfile: each source's own git history is the record of what commit it's at.

Usage

lq_update(path, source = NULL)

Arguments

path

Path to the library.

source

Refresh only this source. Defaults to every source.

Value

A lenguar_update data frame with source, status ("up-to-date", "fast-forwarded", "not-updatable", or "error"), and detail columns. Never stops at the first per-source failure when refreshing every source.

Examples

store <- withr::local_tempdir()
lq_init(store)
lq_update(store)
#> lengua update: 1 source
#>   source        status
#> 1  local not-updatable
#>                                                                         detail
#> 1 source 'local' can't be updated: a local source has no origin to update from