Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/odoo-plus/odootools
Odoo Tools
https://github.com/odoo-plus/odootools
erp odoo odoo-project python
Last synced: about 13 hours ago
JSON representation
Odoo Tools
- Host: GitHub
- URL: https://github.com/odoo-plus/odootools
- Owner: odoo-plus
- License: gpl-3.0
- Created: 2022-06-24T00:12:21.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-07-06T20:51:01.000Z (over 1 year ago)
- Last Synced: 2024-11-08T03:03:42.538Z (5 days ago)
- Topics: erp, odoo, odoo-project, python
- Language: Python
- Homepage:
- Size: 235 KB
- Stars: 21
- Watchers: 6
- Forks: 7
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE.txt
Awesome Lists containing this project
- awesome-odoo - odoo-tools - Generic tool/library to make management of odoo environment management easier. (Tools)
README
# Odoo Tools
[![Python package](https://github.com/llacroix/odoo-tools/actions/workflows/python-package.yml/badge.svg)](https://github.com/llacroix/odoo-tools/actions/workflows/python-package.yml)
[![codecov](https://codecov.io/gh/llacroix/odoo-tools/branch/main/graph/badge.svg?token=MdWK5ZC2ab)](https://codecov.io/gh/llacroix/odoo-tools)A library that provide command line tools to manage an Odoo
environment. The main purpose of the library is to provide
a programmatic API that lets you build tools to automate
management of odoo environment.## How to install
pip install odoo-tools
## Documentation
You can check the documentation hosted [here](https://odoo-tools.readthedocs.io/en/latest/).
## Example of use
It can be used to find modules in addons paths. It can be
used to discover addons paths in directory in a way to provide
an easy way to manage odoo.cfg files without having to break your
head managing things.For example remove all modules that can't be installed in every
configured addons paths:env = Environment()
for module in env.modules.list(filters={'non_installable'}):
module.remove()Define addons paths based on paths in /var/lib/addons:
env = Environment()
env.context.custom_paths.add(Path("/var/lib/addons"))
env.set_config('addons_path', env.addons_paths())This will not simply add `/var/lib/addons` to the `addons_path`. It
will search into this folder for directories that have installable
addons in them. `addons_paths()` returns all possible addons paths
detected based on the environment variables, odoorc file and actual
state of the environment. So it returns everything you need to start
odoo later.