Talk:Pacman/Pacnew and Pacsave

From ArchWiki
Latest comment: 5 October 2023 by Franklin Yu in topic Merge sudoer files

etc-update is unmaintained

The linked Gentoo Wiki mentioned that etc-update is unmaintained, and dispatch-conf is meant to replace it. Has anyone tried dispatch-conf on Arch? Does it support pac* files?--Franklin Yu (talk) 04:26, 1 March 2023 (UTC)Reply[reply]

Locate example is incompatible with plocate

According to plocate(1), When multiple patterns are given, plocate will search for files that match all of them. This is the main incompatibility with mlocate (1) which searches for files that match one or more patterns, unless the -A option is given., hence locate --existing '*.pacnew' '*.pacsave' is not going to work.

Perhaps this should be mentioned in section 4 and/or in locate article itself since this is probably not the only instance of this incompatibility. --Bugmenot3 (talk) 05:27, 23 May 2023 (UTC)Reply[reply]

I came across this issue as well. Is it the case that for plocate we have to use regular expression? This is less readable than multiple globs. --Franklin Yu (talk) 06:31, 23 May 2023 (UTC)Reply[reply]
This seems to be a breaking change from locate(1):

locate reads one or more databases prepared by updatedb(8) and writes file names matching at least one of the PATTERNs to standard output, one per line.

It also seems incompatible with GNU locate, and possibly BSD locate.
Regular expression would work, but it sounds like it cancels the advantages of plocate over mlocate:

-r, --regexp
        Patterns are taken to be POSIX basic regular expressions. See regex(7) for more information. Note that this forces a linear scan through the entire database, which is slow.

Could it be that just running plocate twice would the fastest alternative?
$ plocate --existing '*.pacnew'
$ plocate --existing '*.pacsave'
--Aude (talk) 03:17, 30 May 2023 (UTC)Reply[reply]

Merge sudoer files

Most files can be merged with pacdiff, but /etc/sudoers are supposed to be edited via visudo. Is there any way to merge /etc/sudoers and /etc/sudoers.pacnew reliably? Franklin Yu (talk) 05:16, 5 October 2023 (UTC)Reply[reply]