Will McDonald composed on 2024-12-31 00:35 (UTC+0100):

> What does the following show:
> 
> # ls -l `which dnf`
> # dnf --dump-main-config | grep color

[f41 host gx780]
# ls -l `which dnf`
lrwxrwxrwx 1 root root 4 Dec  5 19:00 /usr/bin/dnf -> dnf5
[root@gx780 ~]# dnf --dump-main-config | grep color
color = never
color_list_available_downgrade = bold,white
color_list_available_install = bold,white
color_list_available_reinstall = bold,white
color_list_available_upgrade = bold,white
color_list_installed_extra = bold,white
color_list_installed_newer = bold,white
color_list_installed_older = bold,white
color_list_installed_reinstall = bold,white
color_search_match = bold,white
color_update_installed = bold,white
color_update_local = bold,white
color_update_remote = bold,black
#

Using these has no impact on output from 'dnf upgrade'. Output is the
same mixture of gray, white and green on my blue vtty background.

> # dnf --setopt=color_list_available_upgrade=white check-update

[f41 host gx780]
Via remote, nothing was apparent except lots of newlines. Using black
instead of white, text is nice black on light background. On vtty,
output is also as expected. So, I tried 4 times with different color
each time:

dnf --setopt=color_list_available_upgrade=[white,gray,red,black] upgrade

None of the colors specified changed anything. 

So with check-update option to dnf, spec are obeyed, while with
upgrade option to dnf, it is ignored. Meanwhile, the content of
/etc/dnf/dnf.conf is being totally ignored, with or without any
'colors = never' line in dnf.conf.

> The parsing of dnf is slightly picky about commas/spaces. If that doesn't
> show the expected values, check your config. If it does show the right
> values, don't know what to say.

I tried without any whitespace in dnf.conf, but that changed nothing.
The man page puts space before and after =.

> Maybe strace the process execution. Do some more digging, there are some
> logs in /var/log/dnf* which might shed some light.

I don't see any:
]# grep -C2 color /var/log/dnf5.log
2025-01-08T22:40:06+0000 [1694] DEBUG Rewriting repo "fedora" with added file 
provides
2025-01-08T22:40:06+0000 [1694] DEBUG Rewriting repo "fedora-cisco-openh264" 
with added file provides
2025-01-08T22:41:48+0000 [1698] INFO --- DNF5 launched with arguments: "dnf 
--setopt=color_list_available_upgrade=gray upgrade" ---
2025-01-08T22:41:48+0000 [1698] DEBUG Loading plugin 
file="/usr/lib64/dnf5/plugins/builddep_cmd_plugin.so"
2025-01-08T22:41:48+0000 [1698] INFO Loaded dnf5 plugin "builddep" 
("/usr/lib64/dnf5/plugins/builddep_cmd_plugin.so") version "1.0.0"
--
2025-01-08T22:41:50+0000 [1698] DEBUG Found running kernel: 
kernel-core-0:6.11.10-300.fc41.x86_64
2025-01-08T22:41:52+0000 [1698] ERROR Command returned error: Operation aborted 
by the user.
2025-01-08T22:41:58+0000 [1700] INFO --- DNF5 launched with arguments: "dnf 
--setopt=color_list_available_upgrade=white upgrade" ---
2025-01-08T22:41:58+0000 [1700] DEBUG Loading plugin 
file="/usr/lib64/dnf5/plugins/builddep_cmd_plugin.so"
2025-01-08T22:41:58+0000 [1700] INFO Loaded dnf5 plugin "builddep" 
("/usr/lib64/dnf5/plugins/builddep_cmd_plugin.so") version "1.0.0"
--
2025-01-08T22:42:00+0000 [1700] DEBUG Found running kernel: 
kernel-core-0:6.11.10-300.fc41.x86_64
2025-01-08T22:42:04+0000 [1700] ERROR Command returned error: Operation aborted 
by the user.
2025-01-08T22:42:15+0000 [1702] INFO --- DNF5 launched with arguments: "dnf 
--setopt=color_list_available_upgrade=black upgrade" ---
2025-01-08T22:42:15+0000 [1702] DEBUG Loading plugin 
file="/usr/lib64/dnf5/plugins/builddep_cmd_plugin.so"
2025-01-08T22:42:15+0000 [1702] INFO Loaded dnf5 plugin "builddep" 
("/usr/lib64/dnf5/plugins/builddep_cmd_plugin.so") version "1.0.0"
--
2025-01-08T22:42:17+0000 [1702] DEBUG Found running kernel: 
kernel-core-0:6.11.10-300.fc41.x86_64
2025-01-08T22:42:20+0000 [1702] ERROR Command returned error: Operation aborted 
by the user.
2025-01-08T22:42:36+0000 [1707] INFO --- DNF5 launched with arguments: "dnf 
--setopt=color_list_available_upgrade=black upgrade" ---
2025-01-08T22:42:36+0000 [1707] DEBUG Loading plugin 
file="/usr/lib64/dnf5/plugins/builddep_cmd_plugin.so"
2025-01-08T22:42:36+0000 [1707] INFO Loaded dnf5 plugin "builddep" 
("/usr/lib64/dnf5/plugins/builddep_cmd_plugin.so") version "1.0.0"
--
2025-01-08T22:45:36+0000 [1715] DEBUG Rewriting repo "fedora" with added file 
provides
2025-01-08T22:45:36+0000 [1715] DEBUG Rewriting repo "FCL" with added file 
provides
2025-01-08T22:48:38+0000 [1719] INFO --- DNF5 launched with arguments: "dnf 
--setopt=color_list_available_upgrade=white upgrade" ---
2025-01-08T22:48:38+0000 [1719] DEBUG Loading plugin 
file="/usr/lib64/dnf5/plugins/builddep_cmd_plugin.so"
2025-01-08T22:48:38+0000 [1719] INFO Loaded dnf5 plugin "builddep" 
("/usr/lib64/dnf5/plugins/builddep_cmd_plugin.so") version "1.0.0"
#
-- 
Evolution as taught in public schools is, like religion,
        based on faith, not based on science.

 Team OS/2 ** Reg. Linux User #211409 ** a11y rocks!

Felix Miata
-- 
_______________________________________________
users mailing list -- users@lists.fedoraproject.org
To unsubscribe send an email to users-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to