Pacman

Welcome to the Pacman bug tracker. Please search the current bugs and feature requests before filing a new one! Use advanced search and select "Search in Comments".

* Please select the correct category and version.
* Write a descriptive summary, background info, and provide a reproducible test case whenever possible.
Tasklist

FS#5571 - unnecessary pacman parameter(s): '-A' and '-U'

Attached to Project: Pacman
Opened by Finn (deTTo) - Wednesday, 11 October 2006, 20:01 GMT
Last edited by Aaron Griffin (phrakture) - Thursday, 13 March 2008, 19:34 GMT
Task Type Feature Request
Category
Status Closed
Assigned To Aaron Griffin (phrakture)
Architecture not specified
Severity Very Low
Priority Normal
Reported Version 0.7.2 Gimmick
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Pacman has both, --add and --upgrade whereas --upgrade (-U) does the same as --add after it checked for an upgradeable version. This makes --add parameter completely unnecessary and we should think about naming a new parameter that does this upgrade/add thing. For example '-I' for install or the like.
Look at http://bbs.archlinux.org/viewtopic.php?t=25932 for further ideas and opinions. :)

cheers,
deTTo
This task depends upon

Closed by  Aaron Griffin (phrakture)
Thursday, 13 March 2008, 19:34 GMT
Reason for closing:  Implemented
Additional comments about closing:  Fixed in git, commit 797c190f93d24ff1e352549f320a0612cd04382b
Comment by Roman Kyrylych (Romashka) - Wednesday, 11 October 2006, 21:27 GMT
I think there is a point in ditto's words, but this comment should be taken into account: http://bbs.archlinux.org/viewtopic.php?p=200629#200629 too.
Comment by Aaron Griffin (phrakture) - Saturday, 03 February 2007, 03:45 GMT
Here's my opinion:
-A and -U are getting to the point where the distinction is a bit silly. I'm all for the -I/--install change, as it makes more sense to me.

That said, removing -A and -U at this point in time, so abruptly, is probably a bad move. So I suggest the following:

Add -I/--install. The -A and -U options will simply call that and output a little warning that the option is old / deprecated / being removed / whatever, and then pass all params to -I (exactly the way -A does not, except with a little message).
Comment by Dan McGee (toofishes) - Saturday, 03 February 2007, 20:33 GMT
I'm with phrakture on this one; I think -I makes a lot more sense for the operation it performs (for downgrading a package, does -U/--upgrade really make sense?).
Comment by Thomas B├Ąchler (brain0) - Sunday, 04 February 2007, 16:18 GMT
IMO it is nonsense to introduce a new option, keep the old ones for backwards compatibility and then have THREE options doing exactly the same. Why can't we just keep -U: everyone uses it anyway, everyone is used to it, so why change it? Just keep -U and let -A stay for backwards compatibility (doing the same as -U) and then only have TWO options doing the same.

About making sense: It doesn't really matter what it means, how much sense does -S make? It only matters what people are used to, nobody will think about what -U once meant.
Comment by Scott H (stonecrest) - Sunday, 04 February 2007, 16:24 GMT
Downgrading a package is an uncommon task, I'm not convinced that the name needs to cover this action. Who wouldn't be able to figure out that -U allows downgrading?

-I has problems of its own. For example, if I have foobar-2.0 installed and then I pacman -I foobar-2.1, I'd expect to have both versions installed. In fact, what I did here was upgrade, or installed AND removed. And, as a new user, I would try to use -I instead of -S to install all of my packages. I mean, I'm supposed to type pacman --sync to install a package from the repo and pacman --install to install locally? Where is the logic in that? (And finally, "I" in general is a bad argument because it looks like "l" :p).

There is no correct term that will cover every use case here. I personally think that -U covers the most common action action (upgrading), doesn't confuse the user with when they should use it versus -S, and is already something that 99% of users are familiar with. It's not broken so don't fix it, especially when the fix is no less confusing than current behavior.
Comment by Aaron Griffin (phrakture) - Monday, 12 February 2007, 00:16 GMT
re-opened and removed from 3.0 bug catcher
Comment by Nagy Gabor (combo) - Monday, 03 March 2008, 16:02 GMT
my vote: -A is needless (some hidden things: its checkdeps is a bit faster, since there is no need to check requiredbys)
Comment by Xavier (shining) - Monday, 03 March 2008, 17:51 GMT
Dan did some work on removing the -A option :
http://code.toofishes.net/gitweb.cgi?p=pacman.git;a=shortlog;h=refs/heads/oven
Afaik, the remaining problems are :
1) clean libalpm too
2) check the add pactest to see if they have an upgrade equivalent. If not, convert them to upgrade (instead of removing them all)

I believe that help is highly welcome on any of these two points, since there was no progress for quite some times now.
Comment by Nagy Gabor (combo) - Monday, 03 March 2008, 18:40 GMT
1.) I think, that (after new parameters of checkdeps) TRANS_TYPE_ADD is formal in alpm, interestingly its only usage is in sortbydeps (as "parameter", which can be replaced by something like '@param reversed').
2.) OFF: add013.py seems to be a bit strange to me.

Loading...