Dnf confusing query options

man dnf shows the following:

Query Options
       Set what information is displayed about each package.

       The following are mutually exclusive, i.e. at most one can be specified. If no query option is given, matching packages are displayed in the standard
       NEVRA notation.

When I tried commands like dnf list --info, dnf list --list etc. each threw an error. So, it is not clear to which command the query options can be applied to. Could anyone pleas explain?

If you look at the man, page, commands where query options can be used are marked so. For example:

Deplist Command
    dnf [options] deplist [<select-options>] [<query-options>] [<package-spec>] 
           Deprecated alias for dnf repoquery --deplist.

A quick search of query-options in the man page suggests that this one and repoquery seem to be the only two commands that accept query options:

Repoquery Command
    Command: repoquery                                                                 
    Aliases: rq                                                                        
    Aliases for explicit NEVRA matching: repoquery-n, repoquery-na, repoquery-nevra
    dnf [options] repoquery [<select-options>] [<query-options>] [<package-file-spec>]

1 Like

repoquery and deplist then. Thanks!

1 Like