openSUSE / opi

OBS Package Installer (CLI)
GNU General Public License v3.0
233 stars 20 forks source link

feat: allow installation of multiple packages in one run #157

Closed nobkd closed 9 months ago

nobkd commented 9 months ago

resolve #154

Introduce -m option (multi package / multi install)

Some changes:

If you agree with the general changes, I'll try to write tests.

nobkd commented 9 months ago

I added a test, but I don't know of a suitable package to be installed. android-tools seems to only be in the main repo for Tumbleweed not Leap. If you have one in mind, please suggest it? Thank you!

Alternatively I could expand the expect to also allow the hardware repo.

asdil12 commented 9 months ago

I guess it would suffice if you would just do the same as 06_install_non_interactive.py but in one opi call (opi -n -m zfs html2text). That should make the test simpler and cover enough of the opi codebase.

nobkd commented 9 months ago

That wouldn't test for plugins in that case. (And it also would just check if it already was installed.) Is that alright?

asdil12 commented 9 months ago

Then use something like opi -n -m zfs resilio-sync html2text yandex-disk.

asdil12 commented 9 months ago

Each test module runs in a fresh container.

nobkd commented 9 months ago

Thank you for the guidance.

asdil12 commented 9 months ago

I guess now I remember why I replaced yandex-disk with resilio-sync in the past: The yandex repo doesn't seem to be that stable. I guess we should drop yandex-disk from the test.

RafaelLinux commented 9 months ago

Could I suggest to avoid "refresh" for each package to install? That's is, if I do:

opi -nm codecs chrome msedge brave vivaldi vscode anydesk teamviewer friture usbimager copyq puddletag ocenaudio autofirma

it will do a "refresh" (for nothing, cause were refreshed with "codecs" application installation).

And a last suggestion in "help" information about "-m" parameter ..... "space separated application names" ;)

Thank you anyway for considering.