Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 20 May 2026 07:05:42 -0700
From:      Mark Millard <marklmi@yahoo.com>
To:        Anthony Pankov <anthony.pankov@yahoo.com>, freebsd-hackers@freebsd.org
Cc:        freebsd-pkgbase@freebsd.org
Subject:   Re: only .pkgnew and only for user-touched files
Message-ID:  <c0a4bd87-fbea-4472-96e6-407a37ab70fc@yahoo.com>
In-Reply-To: <838056711.20260520130025@yahoo.com>

index | next in thread | previous in thread | raw e-mail

On 5/20/26 03:00, Anthony Pankov wrote:
> Hello, 
> 
> after upgrading minor upgrade with pkgbase I found many .pkgsave files such as:
> ..
> /etc/rc.d/noshutdown.pkgsave
> /etc/rc.d/mountd.pkgsave
> /etc/rc.d/FILESYSTEMS.pkgsave
> /etc/rc.d/zfs.pkgsave
> ...
> 
> with changes that do not bothers me:
> 
> diff  /etc/rc.d/noshutdown.pkgsave /etc/rc.d/noshutdown
> 6c6
> < # REQUIRE: var
> ---
>> # REQUIRE: FILESYSTEMS
> -----
> 
> Is it possible during pkgbase upgrade to follow the next logic:
> 
> IF configuration/script file is not modified (== identical  to what was installed by package) then silently replace it with new file
> ELSE  just save new file as .pkgnew (do not touch existing) and print a note.
> 
> Is there already any switches for pkg to do this?
> 
> I ask because sshd_config was replaced and server control lost. But master.passwd was keeped. I'm not complaining just missing single logic.
> 

My impression was that:

) pkg install is what generates pkg.save files, installing those new
  files

) pkg upgrade is what generates pkg.new files, not installing those new
  files

(At least when files are not auto merged?)

I'm not sure that the documentation is explicit about when each is used.

-- 
===
Mark Millard
marklmi at yahoo.com


home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?c0a4bd87-fbea-4472-96e6-407a37ab70fc>