There's more...

The development of complex modules requires various configuration options, which leads to updating the configuration file whenever you want to try any configuration option. Updating the configuration frequently can be a headache, and to avoid this, an alternative way is to pass all configuration options from the command line, as follows:

  1. Activate virtualenv manually:
$ source env/bin/activate
  1. Go to the Odoo source directory:
$ cd src/odoo
  1. Run the server:
./odoo-bin --addons-path=addons,../../local -d test-12 -i account,sale,purchase --log-level=debug

In step 3, we passed a few configuration options directly from the command line. The first is --add-ons-path, which loads Odoo's core add-ons directory, addons, and your add-ons directory, local, in which you will put your own add-ons modules. Option -d will use the test-12 database or create a new database if it isn't present. The -i option will install the account, sale, and purchase modules. Next, we passed the log-level option and increased the log level to debug so that it will display more information in the log.

By using the command line, you can quickly change the configuration options. You can also see live logs in the Terminal. For all available options, see Chapter 1, Installing the Odoo Development Environment, or use the --help command to view a list of all options and the description of each option.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset