Closed Ricky-Tigg closed 6 years ago
@Conan-Kudo dnfdaemon GetRepo(repo_id) does not export such information. Looking at dnf.cli.command.repolist code: Repo-size Repo-pkgs Are both evaluated by another query, so which is the right way, porting those query in dnfdaemon and provide new info, or add them to repo managemet dialog? @Ricky-Tigg any more relevant information?
A decision that would be taken by developers. My own experience tend to indicate that those values would be needed before take place decision to enable any repository,
maybe... i usually enable a repo just because i need something from it, despite of it size for instance... and so more than how many packages the relevant part in my opinion is which ones...
It seems to me that your decision will be the right one according to your own experience. which may conduct you to consider #97 as a partly or entirely irrelevant request.
not really. That is why I asked you if they were the only ones, or you needed other information also... I'm already working on it, in dnfdaemon without good results though...
My mistake! I have to keep on trying (refers to foreign language ). Those ones as well may have a useful purpose and are not yet present in the dnfdragora's existing list:
In your report you quoted dnf -v repolist --enabled Repo-id
that magically enables a repo and then prints out the repositories (those enabled plus the one enabled temporary) information.
Now from UI perspective that means checking the enable flag. Does it sound reasonable to get those info after checking a disabled repository? because it isn't that easy to temporary enable a repo to get them and then to disable it again...
In any cases without pressing the Apply button nothing changes...
From a TUI perspective, checking a repository in disabled state appears clearly to be not adequate for the purpose of the task. As an additional information, the use of another command relying on 'wc' may as well serve as model for the implementation you may plan; it allows for retrieving the number of packages related to a specific repository as a single value, however it does not handle the storage size.
Output resulting from command
$ dnf repoquery --repo=updates-testing | wc -l
is therefore the value resulting from command
$ dnf -v repolist --enabled updates-testing | less
mentioned under the class 'Repo-pkgs : .'
The following command returns the sum of each enabled repository's number of packages (Overall number of packages) resulting from:
$ dnf repoquery | wc -l
For each enabled repository, a valuable information is the value expressed in percentage (optimally with a two digits accuracy) resulting from expression:
(enabled repository's number of packages / Overall number of packages) = _.00 %,
which refers to commands (with 'updates-testing' as model)
(
dnf repoquery --repo=updates-testing | wc -l/ 'dnf repoquery | wc -l') = _.00 %.
Using new dnfdaemon the requested information is now shown into repository info view, that is changed in table in which key are localized (if knwon) and values are in human readable form for some keys (e.g. size for instnace)
OS: Fedora – Installed omponents:
$ dnf list installed | egrep 'dnfdaemon|dnfdragora'
dnfdaemon.noarch 0.3.18-6.fc28 @fedora
dnfdaemon-selinux.noarch 0.3.18-6.fc28 @fedora
dnfdragora.noarch 1.0.1-10.git20180108.b0e8a66.fc28
python3-dnfdaemon.noarch 0.3.18-6.fc28 @fedora
Announced features are not visible in the interface.
Hi Manatools. For a given enabled repository on system, let's assume here the one named updates-testing, maintained by Fedora. In terminal, assuming the command and its subsequent output as model (Note: Red Hat Bugzilla – Bug 1562191):
# dnf -v repolist --enabled updates-testing | less
...
Repo-pkgs : ...
Repo-size : ...
..
The knowledge of this output would have been appropriate as a prerequisite to estimate the possibility of the addition (
# dnf install -y <component> --enablerepo=updates-testing
) of such repository or any others, assuming that all subsequent packages they contain would have to be installed on the system. since their respective values related to digital storage may be huge.As expected it would be valuable for advanced users and especially for beginners that indeed may rely for the package management mainly if not entirely on the GUI tool available in OS' main repository (be it Yumex-DNF or Dnfdragora by whom it was replaced since version 27 of Fedora Desktop) to get that valuable information straight along with the existing one currently located at File -> Repositories, then field section dedicated to repository information. Such enhancement would benefit to Fedora.