-
Notifications
You must be signed in to change notification settings - Fork 422
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Retrieve package installation size #2209
Comments
Some information is available in the If you need to run this calculation regularly, it will be probably pretty easy to write a plugin command or python script that uses libdnf5 API, that will:
|
Here is how such script can look like:
|
Do you have an example of preparing a goal? I couldn't find any complete examples of using libdnf5 |
it's the line |
I just noticed that your issue is filed against dnf4 (which has been replaced by dnf5 since Fedora 41). Since I primarily work on dnf5, I automatically used its API in the example - apologies for that. If you need a dnf4 version, let me know. Also, the current example is equivalent to: |
This version prints installation size per package:
|
Thank you very much for your detailed response and examples. I am seriously considering switching to using the API. If I understand correctly, libdnf4 is written in C++, which means I can use it directly from C#. Where can I find the library on my Rocky Linux 9.2? |
Well, Rocky Linux 9 is exactly why you need the dnf4 API. RHEL 8, 9, and 10 all ship with dnf4, and dnf5 isn’t available there. |
Here is the version of the script, that uses dnf4 API:
|
Could you please clarify whether I can use libdnf4 as a C++ library? |
Let me clarify it.
|
Hi, I couldn't find a command to get the installation size of a package, i.e., the installation size including uninstalled dependencies.
The calculation occurs when calling
dnf install --assumeno
, but running this command doesn't seem convenient, especially since I need to do it for a list of packages, getting the installation size per package.Is there such functionality available?
The text was updated successfully, but these errors were encountered: