Thursday, June 11, 2009

Configure Your Zypper

So i mentioned zypper.conf in my previous post? Yes, Zypper now (since 1.2.0) reads configuration file from /etc/zypp/zypper.conf and from your $HOME/.zypper.conf. It does not have too much to offer right now, appart from the colors, but the point is now we can easily add new ones there, whenever there's a need.

If there is Zypper option that you write too often, it should have it's configuration file counterpart as well, so that it saves you typing. I actually have a list of few, collected over time from users, so i'll be adding them soon. You'll always find the latest list of supported config options here, so stay tuned (and let us know if you need something that's not there yet).

So which value will be used after all, the one from the config file, or the one passed via command line? Here is the override priority order, highest to lowest.
  1. command line options
  2. options from $HOME/.zypper.conf
  3. options from /etc/zypp/zypper.conf
  4. and the lowest priority have the ones from zypp.conf, so that you can override libzypp's settings in zypper, if zypper allows it.

You can use an alternative config file via --config custom/zypper.conf global option. If you do, the other config files (item 2 and 3 above) will be ignored.

todo: Add command for manipulating the configuration files as an alternative to manual editing. The command would list available options with current values and descriptions and would allow to set new values, or restore the defaults.


Anonymous said...

Great to hear about improvements and new features coming into Zypper. However, there is still one feature that I'm eagerly waiting to be implemented: show version number and repository for all actions.

For example, when I'm listing or installing the updates, it would be very nice to see the current version of the packages (in a table).

Another example, just taken from the console:

The following packages are going to be upgraded:
libzypp python-satsolver satsolver-tools

Version numbers? Current and upcoming? Installaing from what repository?

Anyway - as said: glad to see improvement with the Zypper.

jano said...

Already done in 1.2.0, i just wanted to mention the best thing last and did not manage to blog it today :O) I'll do so tommorow, stay tuned.

Juha said...

Sweet! Just red the latest post and indeed - the new summary view is even better that I could have wished. Many thanks to all you developers.

Francis said...

Would be great if you could have an option in there to download-first on any transaction (download all packages, then install all).