odoo-openupgrade-wizard/odoo_openupgrade_wizard/cli_get_code.py
LE GAL SYLVAIN 760d145600 [REF] add ensure_folder_exists system
[ADD] pyttest.ini file + test for cli_build
[ADD] call to gitaggregate
[REF] harmonize release & version words ; remove python version ; add...
[REM] remove towncrier for the time being
[REF\] enable both test and improve : each test should have it's own output folder to reduce gitaggagregate duration
2022-04-08 19:09:24 +00:00

23 lines
650 B
Python

import click
from odoo_openupgrade_wizard.configuration_version_dependant import (
get_odoo_env_path,
)
from odoo_openupgrade_wizard.tools_system import git_aggregate
@click.command()
@click.pass_context
def get_code(ctx):
"""
Build OpenUpgrade Wizard Environment:
- gitaggregate all the repositories
"""
# TODO, make it modular.
# For exemple, possibility to aggregate only 9.0 and 11.0 releaase
for odoo_version in ctx.obj["config"]["odoo_versions"]:
folder_path = get_odoo_env_path(ctx, odoo_version)
repo_file_path = folder_path / "repos.yml"
git_aggregate(folder_path, repo_file_path)