Velvet Star Monitor

Standout celebrity highlights with iconic style.

updates

What is the apt (apt-get) --option used for?

Writer Sophia Terry

Could a kind soul tell me about the apt --option?

  1. What does it do?
  2. How is it used?
  3. What options are set up via this flag?
0

1 Answer

From man apt:

 -o, --option Set a Configuration Option; This will set an arbitrary configuration option. The syntax is -o Foo::Bar=bar. -o and --option can be used multiple times to set different options.

For example, if you are behind a proxy, and want to test with different proxy setting values, you could do this:

apt-get update -o Acquire::http::Proxy ""

When you are not sure of the correct setting value, testing different values using the -o option can be more practical than editing a config file in /etc/apt/apt.conf.d, saving and re-running the command. The -o option let's you skip the file editing part, and play with different values more directly.

More generally, the purpose of this option is to temporarily override any configuration value. As @steeldriver pointed out in a comment, the available options and option syntax are documented in the apt.conf manual page (man apt.conf).

3

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy