On Archlinux it is not recommended to update only one package with the package manager pacman. Let’s say I have 11 packages, and one of them is extra/firefox (true story). Updating only a pacman -S firefox could introduce problems, but installing a new single package if it wasn’t there is okay.

So my question is, could we get around this by removing and installing the same package again in one go: pacman -Rs firefox && pacman -S firefox

  • milk@discuss.tchncs.de
    link
    fedilink
    arrow-up
    0
    ·
    1 day ago

    To add to the other comment, package managers keep a local copy of the list of available packages and the version. When you do a pacman -S xxx the package manager looks up xxx in the cache and downloads the package from whatever mirror youre using as well as any dependencies, looking them up in the same way from your cache. This works for a while even if theres a new update available because mirrors usually keep a few previous versions.

    Once you do a pacman -Sy you update your cache to the latest one. If you then update xxx, it will update xxx and pull in any dependency updates required, but any other packages that depended on the same packages dont get updated, leaving you in a partially upgraded state.