Open bertronika opened 1 year ago
Out of curiosity, what shell are you using and how are you setting the alias.
It's bash, with alias zypper='zypper -s 1'
defined.
OK, thanks.
I'm guessing that in order to having this as a configuration in zypp.conf
, that limitation Zypper has about not supporting global options for sub-commands must be dealt with first. Zypper`s manpage states:
Using zypper global-options together with subcommands, as well as executing subcommands in zypper shell is currently not supported.
Just like you see in the error message you're getting. But now I'm curious to now what are those limitations.
You cant deal with this. A subcommand is a standalone program or shell script (like zypper-log). You can even write your own ones. We have no control about what options those programs support. We (the zypp-team) neither provide nor maintain most of them.
That was the first thing that came to my mind, the "unknown" factor.
We have no control about what options those programs support.
That's why I'm proposing a change, internal to zypper. I've picked zypper.conf
because it already contains color configuration, and table style would complement it. By making it an entry in the configuration file, no more aliases with global options, which conflict with subcommands, would be necessary.
Could that work out Michael? It kind of makes sense to have this as an option in zypper.conf
to avoid that conflict IMO, since it wouldn't be Zypper outputting text, right?. How does Zypper handle sub-commands, is it just like a simple wrapper, or does it do something special?
Zypper has the (little known)
-s, --table-style
argument for changing the characters used when a table is drawn in the command output. I currently set my table style with a shell alias, but doing so presents two problems:Subcommand ... does not support zypper global options.
and terminates)I'm suggesting making the table style setting a config option (in
zypper.conf
). It would help with the discoverability of the setting, prevent conflicts with subcommands and unify zypper's appearance no matter how it is invoked.