[Aptitude-devel] Bug#812829: -o no longer works
積丹尼 Dan Jacobson
jidanni at jidanni.org
Tue Jan 26 23:48:43 UTC 2016
Package: aptitude
Version: 0.7.5-3
file:///usr/share/doc/aptitude/html/en/ch02s05s05.html says
aptitude's configuration is read from the following sources, in order:
1. Configuration file options specified on the command-line.
2. The user's configuration file, ~/.aptitude/config. This file is overwritten when the user modifies settings in the Options menu.
3. The system configuration file, /etc/apt/apt.conf.
4. The system configuration fragment files, /etc/apt/apt.conf.d/*.
5. The file specified by the APT_CONFIG environment variable (if any).
6. Default values stored in /usr/share/aptitude/aptitude-defaults.
7. Default values built into aptitude.
but neglects to mention at what level -o on the command line overrides
any of these. (DOCUMENTATION) BUG1. In fact it doesn't even politely
mention -o one little bit.
In fact it doesn't anymore.
The man page says
-o <key>=<value>
Set a configuration file option directly; for instance, use -o
Aptitude::Log=/tmp/my-log to log aptitude's actions to /tmp/my-log.
For more information on configuration file options, see the section
"Configuration file reference" in the aptitude reference manual.
-v, --verbose
Causes some commands (for instance, show) to display extra
information. This may be supplied multiple times to get more and
more information.
This corresponds to the configuration option
Aptitude::CmdLine::Verbose.
So
# aptitude why python-requests
i python-pip Depends python-requests
# aptitude -v why python-requests|wc
56676 285614 3690866
# aptitude -o Aptitude::CmdLine::Verbose=1 why python-requests|wc
1 4 39
BUG2.
Likewise, if one has
Aptitude::CmdLine::Verbose 1;
in their configuration file,
-o Aptitude::CmdLine::Verbose=0
will no longer turn it off.
Here we see that it must be an aptitude problem, not an apt problem:
# apt-config -o Aptitude::CmdLine::VerboseX=0 dump|grep -i verb
Aptitude::CmdLine::Verbose "1";
Aptitude::CmdLine::VerboseX "0";
CommandLine::AsString "apt-config -o Aptitude::CmdLine::VerboseX=0 dump";
# apt-config -o Aptitude::CmdLine::Verbose=0 dump|grep -i verb
Aptitude::CmdLine::Verbose "0";
CommandLine::AsString "apt-config -o Aptitude::CmdLine::Verbose=0 dump";
More information about the Aptitude-devel
mailing list