Re: FYI: pkg clean with FreeBSD-base disabled cleans out even installed FreeBSD-* base pacakges from the cache

From: Mark Millard <marklmi_at_yahoo.com>
Date: Thu, 23 Oct 2025 13:11:22 UTC
On Oct 23, 2025, at 00:05, Baptiste Daroussin <bapt@FreeBSD.org> wrote:

> On Wed 22 Oct 16:22, Mark Millard wrote:
>> In my exploration of use of having FreeBSD-bsae disabled, I've
>> observed "pkg clean" to remove all the base packages
>> (FreeBSD-*.pkg) from the cache, including the installed ones.
>> 
>> So either it accumulates or is empty.
>> 
>> With FreeBSD-base enabled, the installed ones stick around.
> 
> Yes this is by design we only keep the packages of the enabled repositories.

I'll remind that Colin has reported on planning on
FreeBSD-base being disabled by default to avoid
self destructing deletion activities. See:

https://lists.freebsd.org/archives/freebsd-stable/2025-October/003435.html

QUOTE
I'm planning on putting a "FreeBSD-base" repository configuration into
/etc/pkg/FreeBSD.conf in 15. It will be disabled by default, in order
to avoid "pkg delete -af" problems, but "pkg upgrade -r FreeBSD-base"
should work out of the box.
END QUOTE

Various pkg operations have potentially unintended/surprising
behavior for what would be the default configuration.
That may mean needing having more explicit documentation
setting expectations for the default way things operate.

===
Mark Millard
marklmi at yahoo.com