The various *.conf are all identical except for centos-legacy.conf
which was not configured to use caching yet.
Collapse them into a single dnf.conf, and also allow users to specify
only the distro name (in which case the repos are assumed to be at /usr/share/rpmdistro-repoquery/distros) or a full path.
Also add a usage guide if the script is called without at least 3
arguments.
Tests (added echo to output the command):
rpmdistro-repoquery on main [✘»!]
❯ ./rpmdistro-repoquery fedora 37 foo bar
dnf --config=/usr/share/rpmdistro-repoquery/dnf.conf --setopt=reposdir=/usr/share/rpmdistro-repoquery/distros/fedora --releasever=37 --nogpgcheck repoquery foo bar
rpmdistro-repoquery on main [✘»!]
❯ ./rpmdistro-repoquery ./distros/fedora/ 37 foo bar
dnf --config=./distros/dnf.conf --setopt=reposdir=./distros/fedora --releasever=37 --nogpgcheck repoquery foo bar
The various
*.conf
are all identical except forcentos-legacy.conf
which was not configured to use caching yet.
Collapse them into a single
dnf.conf
, and also allow users to specifyonly the distro name (in which case the repos are assumed to be at
/usr/share/rpmdistro-repoquery/distros
) or a full path.Also add a usage guide if the script is called without at least 3
arguments.
Tests (added
echo
to output the command):Signed-off-by: Michel Alexandre Salim salimma@fedoraproject.org