You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"--downloadonly" is not a global option for dnf5; it's only supported
for certain commands like "download" and "install".
On the surface, "download" seems like a more appropriate command than
"install", but in dnf5 it doesn't download all dependencies; it skips
some of the conditional ones which are needed at install time.
That leaves "install", but in dnf5, "install" doesn't support a
"--downloaddir" option and always writes downloaded RPMs to the cache
directory.
To add dnf5 support, work around the "install" limitation by setting
the cache directory option, and then pruning the output so we end up
with all RPMs stored in a single top-level directory again.
To retain dnf4 support, check whether "--downloaddir" is allowed, and
pass that option if it is. Unlike dnf5, dnf4 won't copy packages from
a local directory to the cache, so the option is required to copy the
RPMs rather than just solving the transaction.
Drop the unnecessary `createrepo_c` command while we're at it, since
none of the subsequent stages care about the resulting repository.
Signed-off-by: Ben Cressey <[email protected]>
0 commit comments