Contribute¶
We accept with pleasure all type of contributions:
- bug reports
- merge proposals
- ideas
- translations
- …
Have a look on the Magento Connector Developer’s Guide which is more complete, most of the information is the same.
The GitHub project is: https://github.com/OCA/connector
Want to start a new connector¶
If you want to start a new connector based on the framework, a sane approach is to read this documentation, especially Connector Concepts and Boostrapping a connector.
Then, my personal advice is to look at the existing connectors (Odoo Magento Connector, Odoo Prestashop Connector). You will also probably need to dive a bit in the framework’s code.
If the connector belongs to the e-commerce domain, you may want to reuse the pieces of the E-Commerce Connector module.
Naming conventions¶
The naming conventions for the new projects are the following:
Name of the project if it is in the OCA:
connector-xxx
- Name of the Odoo module:
- connector_xxx
- Example:
https://github.com/OCA/connector-magento
connector_magento
Actually, the Magento and Prestashop connectors do not respect this convention for historical reasons (magentoerpconnect, prestashoperpconnect). New projects should ideally respect it.
Creating or maintaining a translation of this doc¶
- Install Odoo, its dependencies, sphinx, sphinx_bootstrap_theme and sphinx-intl
- Add this patch to sphinx-intl (until merged) to support fuzzy translations
- create an empty database with the connector module installed
cd connector/doc
- rebuild the gettext .pot source catalogs:
make gettext
- update the .po translation files from the latest .pot files (here for
language ‘fr’):
sphinx-intl update -l fr -p _build/locale
- create or edit the translation in the .po files:
poedit locale/fr/LC_MESSAGES/*.po
- compile the .po files into .mo files:
sphinx-intl build
- build the translated documentation to html:
make SPHINXOPTS="-Dlanguage=fr" html
The same using a buildout:
$ mkdir buildout && cd buildout
$ wget https://bitbucket.org/anybox/public_buildbot_buildouts/raw/tip/odoo-connector.cfg -O buildout.cfg
$ wget https://bitbucket.org/anybox/public_buildbot_buildouts/raw/tip/bootstrap.py
$ python bootstrap.py
$ bin/buildout
$ createdb connectordb
$ bin/start_openerp -d connectordb --stop-after-init
$ cd connector/connector/doc/
$ ../../../bin/sphinx-build -d connectordb -- -b gettext ./ _build/locale/
$ ../../../bin/sphinx-intl -d connectordb -- update -l fr -p _build/locale/
$ poedit locale/fr/LC_MESSAGES/*po
$ ../../../bin/sphinx-intl -d connectordb -- build
$ ../../../bin/sphinx-build -d connectordb -- -D language=fr -b html ./ _build/html/
Then you can see the result in _build/html/ and submit a Pull Request. Repeat the 5 last steps to update the translation if modified upstream.