After some IRC discussion on how I use facets in X, and how other
people are implementing them in other consolidations, I'm not sure
if we're doing what's intended or most desirable.

Right now for instance, I've got these pkgmogrify transforms in X to
set facets:

<transform file path=usr/share/doc/.* -> default facet.doc true>
<transform file path=usr/share/doc/.*\.html$ -> default facet.doc.html true>
<transform file path=usr/share/doc/.*\.pdf$ -> default facet.doc.pdf true>
<transform file path=usr/share/man/.* -> default facet.doc.man true>

<transform file path=usr/include/.*\.h$ -> default facet.devel true>
<transform file path=usr/share/man/man3.* -> default facet.devel true>

So for instance, /usr/share/doc/X11/input/XKB-Enhancing.txt has facet.doc=true,
and /usr/share/doc/X11/input/XKB-Enhancing.html has facet.doc=true and
facet.doc.html=true.

If I do "pkg change-facet facet.doc=False" it removes XKB-Enhancing.txt but not
the html one, which is not what I'd expect as a user.  After reading the
pkg gate's doc/facets.txt, the locale section makes it sound like we should
never tag a document with facet.doc=True, but always with
facet.doc.<something>=True, even though facet.doc is specifically listed as
one of the defined facets in facets.txt.

Should "facet.doc=False" imply "facet.doc.*=False" as well?  Or should I remove
my facet.doc=true tags and make sure the text files are facet.doc.text=true
instead?   And then make sure that "facet.doc" without any ".*" is deleted
from the docs?

As for the man pages, since the documented & implemented behaviour is that
they're OR'ed  together, "facet.doc.*=False" doesn't delete the man3* man
pages when tagged as above, or the localized man pages using the transforms
ON recently added to tag them with facet.locale.$LANG in addition to
facet.doc.man, since one of their facets will still be true, which is again,
not what a user running "pkg change-facet facet.doc.man=False" would expect.

While we could make some sort of compound facet ("facet.doc.man.devel" or
"facet.doc.man.locale.ja") that wouldn't do the expected thing for
"pkg change-facet facet.doc=False".

Should we perhaps have facet sets for cases like this?   For instance, have the
man3* man pages tagged with facet.doc.man,devel=true to require both facets be
set to true to install them?

-- 
        -Alan Coopersmith-        [email protected]
         Oracle Solaris Platform Engineering: X Window System

_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss

Reply via email to