Pacman

Historical bug tracker for the Pacman package manager.

The pacman bug tracker has moved to gitlab:
https://gitlab.archlinux.org/pacman/pacman/-/issues

This tracker remains open for interaction with historical bugs during the transition period. Any new bugs reports will be closed without further action.
Tasklist

FS#51460 - [pacman] Allow per-repository NoExtract

Attached to Project: Pacman
Opened by Earnestly (Earnest) - Thursday, 20 October 2016, 14:38 GMT
Last edited by Jonathan Roemer (pid1) - Thursday, 20 October 2016, 17:58 GMT
Task Type Feature Request
Category Packages: Core
Status Unconfirmed
Assigned To No-one
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 0%
Votes 1
Private No

Details

My use case is packaging personal configurations and in light of this some software requires configurations to operate, or they don't implement the /usr/lib and /etc override mechanism.

In these cases I'd like to add NoExtract to the repository which contain configuration files I would like to replace from my own repository.

An example is nftables: (See https://bugs.archlinux.org/task/49292)

[extra]
NoExtract = etc/nftables.conf
Include = /etc/pacman.d/mirrorlist

This would allow me to package my own /etc/nftables.conf in [earnestly] and avoid any conflicts.

PS: Even though the manuals states "Include another config file. This file can include repositories or general configuration options." under "REPOSITORY SECTIONS", this doesn't seem to include general configurations like NoExtract.
This task depends upon

Comment by Andrew Gregory (andrewgregory) - Friday, 21 October 2016, 14:12 GMT
This would not do what you want, NoExtract is not considered during conflict checks.

The manual is not saying that you can magically use global options on a per-repository basis just by putting them in an included file; it means that you can include global options in an included file. The following is perfectly valid:

foo.conf:
Server = http://foo.com/
[options]
TotalDownload

bar.conf:
[core]
Include = foo.conf
Comment by Earnestly (Earnest) - Friday, 21 October 2016, 22:48 GMT
Ah that's a shame to hear, do you have any ideas for how this could be done or how this specific use case could work? One alternative would be to simply repackage the repo packages locally without configurations for each package I care about.

As for the manual, yes I gathered that much but mentioned it because "Include" is mentioned under the 'REPOSITORY SECTIONS' manual section, perhaps this artefact harkens back to the time pacman had a two-pass parser you mentioned in #archlinux-pacman?
Comment by Eli Schwartz (eschwartz) - Wednesday, 02 May 2018, 19:09 GMT
As earnestly mentioned on IRC today, this feature would probably make a lot more sense per *package*, not per *repo*.

It doesn't necessarily need to be NoExtract itself, but the ability to essentially suppress file conflicts and determine which package should provide a given file could definitely have some interesting use cases beyond giving up and marking them as conflicts=(), e.g.  FS#54040  could be worked around on the user end by choosing which /usr/bin/csc to keep.

The other use case mentioned today is to provide an alternative, simplified /usr/bin/locale-gen currently featured in the glibc-git package in the AUR. Or simply, as the initial request discussed, creating a package which contains overridden versions of various /etc configurations. Users who wish to locally package configurations and system modifications might not want to rebuild every package and track upstream in order to do it, which is required even to repackage file marked as a backup file.

Loading...