1APT-CONFIG(8) APT-CONFIG(8)
2
3
4
6 apt-config - APT Configuration Query program
7
9 apt-config [ -hv ] [ -o=config string ] [ -c=file ] { shell | dump }
10
11
13 apt-config is an internal program used by various portions of the APT
14 suite to provide consistent configurability. It accesses the main con‐
15 figuration file /etc/apt/apt.conf in a manner that is easy to use by
16 scripted applications.
17
18 Unless the -h, or --help option is given one of the commands below must
19 be present.
20
21 shell shell is used to access the configuration information from a
22 shell script. It is given pairs of arguments, the first being a
23 shell variable and the second the configuration value to query.
24 As output it lists a series of shell assignments commands for
25 each present value. In a shell script it should be used like:
26
27
28 OPTS="-f"
29 RES=`apt-config shell OPTS MyApp::Options`
30 eval $RES
31
32 This will set the shell environment variable $OPTS to the value
33 of MyApp::Options with a default of -f.
34
35 The configuration item may be postfixed with a /[fdbi]. f
36 returns file names, d returns directories, b returns true or
37 false and i returns an integer. Each of the returns is normal‐
38 ized and verified internally.
39
40 dump Just show the contents of the configuration space.
41
43 All command line options may be set using the configuration file, the
44 descriptions indicate the configuration option to set. For boolean
45 options you can override the config file by using something like
46 -f-,--no-f, -f=no or several other variations.
47
48 -h
49
50 --help Show a short usage summary.
51
52 -v
53
54 --version
55 Show the program version.
56
57 -c
58
59 --config-file
60 Configuration File; Specify a configuration file to use. The
61 program will read the default configuration file and then this
62 configuration file. See apt.conf(5) for syntax information.
63
64 -o
65
66 --option
67 Set a Configuration Option; This will set an arbitrary configu‐
68 ration option. The syntax is -o Foo::Bar=bar.
69
71 apt.conf(5)
72
74 apt-config returns zero on normal operation, decimal 100 on error.
75
77 See the APT bug page <URL:http://bugs.debian.org/src:apt>. If you wish
78 to report a bug in APT, please see /usr/share/doc/debian/bug-report‐
79 ing.txt or the reportbug(1) command.
80
82 APT was written by the APT team <apt@packages.debian.org>.
83
84
85
86 02 August 2007 APT-CONFIG(8)