opkg-upgrade icon indicating copy to clipboard operation
opkg-upgrade copied to clipboard

Blacklist packages

Open tavinus opened this issue 4 years ago • 5 comments

Got a donation asking to be able to blacklist packages.
Seems like a nice addition to avoid problematic packages that should not be upgraded.

Need more research on some things:

  • Can we blacklist from opkg itself?
  • Can we blacklist on repository configuration?
  • Does opkg has any kind of pinning?
  • Should we save the information of blacklisted packages on a file? Where?
  • Should we just have a parameter to ignore packages on the fly?

tavinus avatar Sep 12 '19 18:09 tavinus

I'd make it simple and create a config file with a simple list of packages to be ignored. i.e all core packages should be in the default config file, as you don't want to mess with mlwifi for example in between versions

Goro2030 avatar Sep 12 '19 19:09 Goro2030

My preferred solution would be to have a single bash var inside a config file that could be sourced by the main program. Seems easy enough, could be an array or a string with package names separated by spaces.

Then we would still need to decide some stuff:

  • Where to put this config file
  • How to add / remove entries to it (manually editing config files could break the whole script)
  • Config files should probably have a default PATH, but having a parameter to set a custom config PATH would be nice
  • This enhancement should probably come together with the ability of selecting packages to install (wishlist - https://github.com/tavinus/opkg-upgrade/issues/3). Then we could just select the packages to be blacklisted from the list as well. Should have both interactive and non-interactive options if possible.

tavinus avatar Sep 12 '19 20:09 tavinus

Also, we need to create a default list of those problematic packages, but that can be tricky as well.

Different versions and archs may have different lists, which will add a lot complexity.

But then other people could contribute with their black lists as well.

tavinus avatar Sep 12 '19 20:09 tavinus

I guess we should just use uci for the config.
Makes more sense and is a lot more powerful.
https://openwrt.org/docs/guide-user/base-system/uci

This way we just use uci to add/read/etc the config file on /etc/config/opkg-upgrade .
This could also make it easier to create a web interface in the future.

tavinus avatar Sep 12 '19 20:09 tavinus

i just started play with this feature. Problem arises, when excluded packet is listed in dependencies of other package. My idea is to make "blacklist" as hard suggestion, but not strict reject(or you think it is better to exclude some important updates). But choice can be done with some start parameter

lareq avatar Oct 21 '20 12:10 lareq