Skip to main content

update

Function update 

Source
pub fn update(cfg: &Config, opts: UpdateOpts) -> Result<UpdateReport, PkgError>
Expand description

Refresh deps and bump tag pins as appropriate, then re-install.

Walks [deps] (or just opts.name), classifies each entry via the decision table below, and — unless opts.dry_run — applies the changes:

dep pinforceoutcome
rev = "..."anySkipped("rev pin")
branch = "..."anyRefresh
tag = "...", exactfalseSkipped("exact tag pin …")
tag = "...", exacttrueTagBumped (or Skipped("already at …"))
tag = "...", prefixanyPrefixResolved (or Skipped("no match"))
tag = "...", junkanySkipped("tag '…' is not SemVer")
no pinanyRefresh

TagBumped rewrites the manifest’s tag value in place through toml_edit (comments / key order preserved). Anything other than Skipped triggers a full install afterwards.

§Errors