paru icon indicating copy to clipboard operation
paru copied to clipboard

Allow custom pacman.conf file for --chroot similar to --makepkgconf option

Open acxz opened this issue 3 years ago • 3 comments

Have you checked the readme and man page for this feature? Yes the closest I could find was the following feature: https://github.com/Morganamilo/paru/blob/6ccd29bd8eb4106275c18202fe2f1065489b4221/man/paru.8#L262-L264 Have you checked previous issues for this feature? Yes, no related issues exist.

This feature request is to allow users to use a custom pacman.conf file when building in the chroot. i.e. allow users to specify the -C flag of mkarchchroot.

I'm guessing there needs to be a propagation of this variable down to the following line of code: https://github.com/Morganamilo/paru/blob/fae9829d8623fc3701eef41142a318149258ed96/src/chroot.rs#L48-L50

acxz avatar Apr 06 '22 18:04 acxz

What's the motive for this?

Morganamilo avatar Apr 06 '22 19:04 Morganamilo

The particular use case that I came across is when I am attempting to build a package via --chroot that requires a package that I have listed under IgnorePkg in my pacman.conf. I have a version of the package installed but I don't want to update it. Thus I set it to IgnorePkg, however, when mkarchchroot reads my /etc/pacman.conf it will see that the IgnorePkg and not install it in the chroot in the first place.

This itself is a trickle down issue of the following pacman feature request: https://bugs.archlinux.org/task/17127?string=IgnorePkg which would solve my original problem.

I posted this feature request as I thought a specified pacman.conf can have other uses. In any case, mkarchchroot does allow a custom pacman.conf (see) and having a similar pass through for pacmanconf as for makepkgconf makes sense.

acxz avatar Apr 06 '22 19:04 acxz