[pacman-dev] [PATCH 0/3] Add "Usage" option for repos
d at falconindy.com
Tue Aug 20 21:57:15 EDT 2013
On Mon, Aug 05, 2013 at 11:17:13AM +1000, Allan McRae wrote:
> On 05/08/13 03:25, Dave Reisner wrote:
> > I've been using these patches for a while now (see the author date on the
> > actual patches) and would like to present them again for feedback. I've
> > found it tremendously useful (particularly as an Arch packager) to be able
> > to keep an eye on other repos like [staging] without actually having them
> > enabled.
> I like these patches, and I believe I had the last version of them on my
> working branch for a while. I have just one comment for some discussion:
> > +*Usage =* ...::
> > + Set the usage level for this repository. This option takes a list of
> > + which must be at least one of the following:
> > + *Sync*;;
> > + Enables refreshes for this repository.
> > + *Search*;;
> > + Enables searching for this repository.
> > + *Install*;;
> > + Enables installation of packages from this repository during a
> > + operation.
> > + *Upgrade*;;
> > + Allows this repository to be a valid source of packages when
> > + a '\--sysupgrade'.
> > + *All*;;
> > + Enables all of the above features for the repository. This is the
> > + if not specified.
> I think the description here needs to be clearer. Sync allows use to
> list the contents of the repo with -Sl?
Acting on a repo explicitly should ignore usage. I suppose I could make
> Search, Install and Upgrade obviously imply Sync. Does Install only
> allow explicit installation - i.e. "-S repo/foo", or is "-S foo" enough?
If you set 'Install' for Usage, '-S foo' is sufficient.
> Is Upgrade different from All? I would assume it implies Install (just
> by description).
-U has no concept of repos. Usage isn't relevant here.
> So here is my suggestion. Can we put these in an order where the higher
> up ones imply everything below?
> Sync < Search < Install < Upgrade == All
Hrmm. So, I suspect that 'Sync Search' will be the common alternative as
'Sync' or 'Search' on their own are not very useful, though 'Sync' alone
will still allow for -S $repo/$pkg. 'Install' without 'Sync' *and*
'Search' isn't very useful either, but if you want the effects of all 3
of these, you simply don't specify usage.
I'm +0 on the idea of adding a hierarchy. Anyone else have an opinion?
More information about the pacman-dev