GNU bug report logs -
#78661
30.1; pcomplete/dnf does not work with dnf5
Previous Next
Reported by: Rahguzar <rahguzar <at> mailbox.org>
Date: Sun, 1 Jun 2025 07:50:06 UTC
Severity: normal
Found in version 30.1
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
Message #25 received at 78661-done <at> debbugs.gnu.org (full text, mbox):
> From: Rahguzar <rahguzar <at> mailbox.org>
> Cc: Eli Zaretskii <eliz <at> gnu.org>, 78661 <at> debbugs.gnu.org
> Date: Sun, 22 Jun 2025 13:25:28 +0500
>
> Hi Augusto and Eli,
>
> Augusto Stoffel <arstoffel <at> gmail.com> writes:
>
> > On Sat, 14 Jun 2025 at 16:28, Eli Zaretskii wrote:
> >
> >> Augusto, any comments or suggestions?
> >>
> >>> Cc: arstoffel <at> gmail.com
> >>> Date: Sun, 01 Jun 2025 12:49:02 +0500
> >>> From: Rahguzar via "Bug reports for GNU Emacs,
> >>> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
> >>>
> >>>
> >>> Dear Emacs maintainers,
> >>>
> >>> Recently released Fedora 42 defaults to dnf 5. This had the effect of
> >>> breaking pcomplete completions provided by pcomplete/dnf. I have worked
> >>> around the problem in my init file by means of advice.
> >>>
> >>> I can send a patch with the changes needed to make completion work with
> >>> dnf 5. However, I want to make some additional changes too so I would
> >>> like to ask some questions first (I have cced Augusto Stoffel since he
> >>> added the code in question):
> >>>
> >>> 1) I think "upgrade" should offer completions from installed packages
> >>> but currently it offers completions from all packages. Is there a reason?
> >
> > No, this change makes sense.
> >
> >>> 2) Currently completions of package names come with a very long version
> >>> string which I have never needed and have to delete by hand. Is it ok to
> >>> remove that?
> >
> > I think I used to get that with shell completions so there might be a
> > reason it was done that way, but seems reasonable to me to remove the
> > versions.
> >
> >>> 3) The most reliable way of getting package names without version string
> >>> is (in my opinion) to use the dnf repoquery command. It also has the
> >>> (slight) advantage of not requiring sqlite3. However, although I can get
> >>> the list of installed and available packages from it, I can't get the
> >>> list of 'not installed' packages. On the other hand the current version
> >>> seems to return the same list for 'not installed' and available packages.
> >>> Is it ok to just remove the 'not installed' case and use the available
> >>> packages instead?
> >
> > I think this is fine too.
>
> I have attached a patch implementing these changes. It also provides
> better support for dnf repoquery --what* commands and adds some aliases
> to the list of subcommands for which completion of package names is
> provided.
Thanks, now installed on the master branch, and closing the bug.
P.S. Please see the minor edits I needed to do on your commit log
message, and try to follow these conventions in the future.
This bug report was last modified 23 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.