Regarding the merge of pacman.conf

I saw some comments in the stable update announcement that if you never touched pacman.conf you can just Overwrite instead of Merge what is my case. Can I just do that instead?
I did everything (except the merge): update via terminal as I always do (I only use pamac to update flatpaks) and installed lib32-libnm so Steam doesn’t crash. If I do nothing regarding the merge will the system break someway, because everything is working fine!
If someone is in the same situation as me let me know your opinion about this, gladly I will take any advice!

It may break at some point

The community repo was included into the extra repo.
Without removing the old lines, your package managers will continue to ask the servers for the community files.
At the moment it works, because they are still available but they might be removed in the future.

1 Like

It would be simpler for new users to install meld to compare pacman.conf.pacnew to pacman.conf in a GUI

sudo meld /etc/pacman.conf.pacnew /etc/pacman.conf

then you can merge any new configuration without losing user preferences

1 Like

Thanks, I have vim installed by preference, works the same right?
I think to compare and merge that file I must have at least vim installed…
I’m just asking because since I never touched those files in any way I post the question if I can just select the Overwrite option instead of Merge…

I started this thread for this exact purpose.
Pretty short thread (intentionally closed it very early to stay short and concise), covers why to not use merge, how to accomplish the change and why to do it in certain ways.

Maybe it will help. :slight_smile:

Never used vim to know if it behaves similar to meld

Meld shows both files and highlights any differences

1 Like

Exactly. The difference is the removal of community repo. Don’t worry if you have software from there, all is now moved in extra.

Ok. Then I just gonna Overwrite then, probably.
I do snapshots of the system regularly so if something goes wrong I can always go back.
I just wanna know if someone was in the same situation and if the overwrite option worked for them…

What I usually do if there is a pacnew:

Integrate the old settings into the pacnew and to use this file.

Please pardon my paranoia, but I always worried that this fell under the “don’t use sudo with GUI applications” advice.

As an alternative, on KDE Plasma I have recently been using kompare and kio-admin to merge .pacnew files without sudo.

kompare -c /etc/pacman.conf.pacnew admin:///etc/pacman.conf

It does.
If pacdiff -s is used then it would be fine and use temporary files, calling sudo to apply changes afterwards and not to the GUI application itself.

It also is somewhat related to those common env vars topic again.


So then same benefit for single files:

sudoedit /etc/pacman.conf
# or
sudo -e /etc/pacman.conf

(open temp file to be applied to pacman.conf … uses micro from above settings)

Another way is to use gvfs or kio …

meld admin:////etc/pacman.conf.pacnew admin:////etc/pacman.conf

I actually patched pacdiff at one point to use gvfs/kio with a new function “(E)dit”.
But its somewhat redundant with the -s option. (as then “(V)iew” works fine for edits).

1 Like

I have already posted the simplest way I know of to check and merge both files
using admin:///etc/pacman.conf would still request password for root privileges

@Takkage - OP appears to be using Xfce not KDE


It will then be xed admin://… Or gedit admin://…
Or just

sudo DIFFPROG=meld pacdiff

Manjaro Xfce has nano and mousepad text editors but users can install meld or konsole for comparing files or text editors micro, vim, emacs, xed, gedit if they prefer

Yes I’m using Manjaro XFCE and very happy with it!
So if I choose the Overwrite option is like revert to default settings in pacman and pamac settings will also revert to default too? Because I have AUR and Flatpaks support enabled.
For now everything working as it should and I do snapshots regularly so all ok for now, thanks all of you guys for your feedback regarding this subject, I hope this also help other people too, I think it was not just me with questions about this!
Once again thank you very much.

Btw i saw someone in the forum sugesting to do this instead:

sudo mv /etc/pacman.conf /etc/pacman.conf.pacsave
sudo mv /etc/pacman.conf.pacnew /etc/pacman.conf

Is this usefull too?

Its about equivalent to backing up the file first and then overwriting - with the additional caveat that tools like pacdiff will continue to have an entry because it handles all of those related extensions (pacnew, pacsave, pacorig). IE - if you ran pacdiff again you would be prompted for pacman.conf and pacman.conf.pacsave just as you had previously been with the pacnew.

1 Like

I see. Another question if I may, using those commmands do I need to run
sudo pacman -Syu "pacman>=6.0.2-11" before and sudo pacman -Sc after?
Also pamac revert to default settings right, and need to enable AUR and flatpak support again?

Is just ensuring you get the necessary set of updates (with the new pacman.conf and all)
Functionally you need to sync/update first, handle the pacnews, sync/update again (with the proper repos now), and clear out the old repo database (pacman -Sc).

1 Like