On 09/ 3/10 02:12 PM, Shawn Walker wrote:
On 09/ 3/10 02:06 PM, Alan Steinberg wrote:
I also saw why we assumed it was only a warning. It looks like this step
that followed our "pkgrepo create" does the creation on an empty
directory:

$ pfexec pkg create file:///var/pkg/testrepo
pkgrepo: A package repository (or directory) already exists at
'/var/pkg/testrepo/'
$ ls /var/pkg/testrepo/
[EMPTY]
$ pfexec pkgrepo -s file:///var/pkg/testrepo set
publisher/prefix=opensolaris.org
$ ls /var/pkg/testrepo/
file pkg5.repository

This would eliminate the need to run pkgrepo create. Was that
intentional?

Yes, for compatibility with older repositories during format upgrade,
and because the new format doesn't require any of the directory
structure the old ones had.

To be clear, although it was intentional that the command be able to deal with this, I wouldn't rely on this behaviour for this particular scenario.

I've filed bug 16979 to change the repository class to allow empty target directories for creation operations.

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

Reply via email to