FS#38058 - Option to force-reinstall a package's dependencies
Attached to Project:
Pacman
Opened by Jerome Leclanche (Adys) - Sunday, 08 December 2013, 12:00 GMT
Last edited by Allan McRae (Allan) - Saturday, 08 March 2014, 02:29 GMT
Opened by Jerome Leclanche (Adys) - Sunday, 08 December 2013, 12:00 GMT
Last edited by Allan McRae (Allan) - Saturday, 08 March 2014, 02:29 GMT
|
Details
When doing pacman -S <package> to reinstall or upgrade
a package, add a flag to force reinstall the dependencies as
well; and possibly, a --cascade option (symmetrically to
-Rcs behaviour's).
This is especially useful for cases where the user is selectively upgrading packages, but a package breaks due to a rebuild or similar. |
This task depends upon
Closed by Allan McRae (Allan)
Saturday, 08 March 2014, 02:29 GMT
Reason for closing: Won't implement
Additional comments about closing: pactree -u <pkg> | pacman -S -
Saturday, 08 March 2014, 02:29 GMT
Reason for closing: Won't implement
Additional comments about closing: pactree -u <pkg> | pacman -S -
Partial upgrades aren't supported.
This option used to exist but it was removed along with SyncFirst because of the problems it causes. You'd need a more compelling (supported) case for this to be considered for reintroduction.
I get that partial upgrades aren't supported, but they are sometimes necessary; eg in the case where an update is known to break a system but the culprit itself isn't known.
To be clear, this would be an *opt-in* flag, not default behaviour. If the issues are minor and infrequent, the flag itself may be documented as recommended against (Much like --force and plenty of others).
The current alternatives are pretty silly... one from IRC (though could be improved a lot): <Ogion> jleclanche: ruby -e 'print("echo pacman -S ", ARGV[0], `LC_ALL=C pacman -Si #{ARGV[0]} | egrep "^Depends On"`.split.drop(3).join(" "))' arandr
The other argument I could give you is when a package is broken but the breakage may be caused by any of its libs. A pacman -S --deps --cascade (or whatever) could be a better alternative to pacman -S.
pactree -d1 -u $package | pacman -S $package -
The historical background on why not to do this is on the bug tracker. SyncFirst provided the behavior of what my shell pipeline does, and it was insufficient because it lead to broken dependencies elsewhere during the transaction. So, we applied recursion (essentially calling pactree -u $package | pacman -S $package -). Now you break uninvolved programs because you updated a reverse dependency they can't load/interface with.
Well, ultimately adding this option (back) is up to you. I think theres a case for it (namely, even if the partial upgrade argument is not accepted, the broken packages one is valid). I don't think anything involving pactree is an acceptable alternative; it's not a package installed by default and people can't find out about it by just reading pacman --help, which is where they're most likely to look when doing this operation.
2c
Uh, really? pactree is part of pacman proper.
Closing as won't implement given we provide all needed tools to do this.