[pacman-dev] [PATCH RFC] DWIM if user attempts to sync on a file
Andrew
coldpie at fastmail.com
Fri Jun 17 13:44:47 UTC 2016
On Thu, Jun 16, 2016, at 11:19 PM, Allan McRae wrote:
> On 16/06/16 10:01, Andrew Eikum wrote:
> > I get bit by this fairly often when I build AUR packages. From my
> > perspective as a user, the distinction between -U and -S seems
> > irrelevant: I just want to install this package. So let's just have
> > pacman offer to Do What I Mean and install the files if I use -S when I
> > should have used -U.
> >
> > Signed-off-by: Andrew Eikum <coldpie at fastmail.com>
> >
> > ---
> >
> > RFC because this lacks tests and maybe UI polish, but I thought I'd see
> > if there's interest in this change before I put more effort into it.
>
> I am interested... I have a more general comment. Why do we
> distinguish between -S and -U at all?
>
> @Andrew: you are looking at unified transactions. Do you think merging
> -S and -U makes sense.
Speaking only as a simple end user, I don't see any distinction. Upgrade
seems redundant. The Upgrade Options section of the manpage even says
its options also apply to sync operations. The one distinction I can
think of is whether the arguments are files, or package names from the
repository. I guess if you had a local file named e.g. "qt" this
distinction would be important; but I don't think that will occur in the
real world.
So, another take on this patch would be to move local file and explicit
URL handling into -S and make -U a synonym for -S, yes?
Andrew
More information about the pacman-dev
mailing list