From 7f6a368a84d21e709063b651655093dda2fded9a Mon Sep 17 00:00:00 2001 From: Sylvain LE GAL Date: Tue, 24 Mar 2026 09:52:59 +0100 Subject: [PATCH] [FIX] Hide OCA banner image, if it's not an OCA repo. Rational: this tool can be used for repo out of OCA context. For the time being, a big OCA banner is displayed in all description of modules. This gives the impression that the module was developed by the OCA and complies with OCA standards. (quality, stability, etc.), which is not true. This commit so removes the OCA banner in such situation. (similar as in the end of the template, with the sentence 'To learn how please visit https://odoo-community.org/page/Contribute.'). --- tests/data/readme_tests/addon1/README.expected-acme.rst | 4 ---- .../addon_one_maintainer/README.expected-acme.rst | 4 ---- .../addon_two_maintainers/README.expected-acme.rst | 4 ---- tools/gen_addon_readme.rst.jinja | 2 ++ 4 files changed, 2 insertions(+), 12 deletions(-) diff --git a/tests/data/readme_tests/addon1/README.expected-acme.rst b/tests/data/readme_tests/addon1/README.expected-acme.rst index 1555c4a9d..5835ded6e 100644 --- a/tests/data/readme_tests/addon1/README.expected-acme.rst +++ b/tests/data/readme_tests/addon1/README.expected-acme.rst @@ -1,7 +1,3 @@ -.. image:: https://odoo-community.org/readme-banner-image - :target: https://odoo-community.org/get-involved?utm_source=readme - :alt: Odoo Community Association - ======= addon 1 ======= diff --git a/tests/data/readme_tests/addon_one_maintainer/README.expected-acme.rst b/tests/data/readme_tests/addon_one_maintainer/README.expected-acme.rst index 7d6256ec5..40d7a6238 100644 --- a/tests/data/readme_tests/addon_one_maintainer/README.expected-acme.rst +++ b/tests/data/readme_tests/addon_one_maintainer/README.expected-acme.rst @@ -1,7 +1,3 @@ -.. image:: https://odoo-community.org/readme-banner-image - :target: https://odoo-community.org/get-involved?utm_source=readme - :alt: Odoo Community Association - ==================== addon one maintainer ==================== diff --git a/tests/data/readme_tests/addon_two_maintainers/README.expected-acme.rst b/tests/data/readme_tests/addon_two_maintainers/README.expected-acme.rst index ed575f5f1..ae5a2dde8 100644 --- a/tests/data/readme_tests/addon_two_maintainers/README.expected-acme.rst +++ b/tests/data/readme_tests/addon_two_maintainers/README.expected-acme.rst @@ -1,7 +1,3 @@ -.. image:: https://odoo-community.org/readme-banner-image - :target: https://odoo-community.org/get-involved?utm_source=readme - :alt: Odoo Community Association - ==================== addon one maintainer ==================== diff --git a/tools/gen_addon_readme.rst.jinja b/tools/gen_addon_readme.rst.jinja index 59e1929e3..71fd57435 100644 --- a/tools/gen_addon_readme.rst.jinja +++ b/tools/gen_addon_readme.rst.jinja @@ -6,11 +6,13 @@ {{ fragments[name] }} {% endif %} {%- endmacro -%} +{% if org_name == 'OCA' -%} .. image:: https://odoo-community.org/readme-banner-image :target: https://odoo-community.org/get-involved?utm_source=readme :alt: Odoo Community Association +{% endif -%} {{ '=' * manifest.name|length }} {{ manifest.name }} {{ '=' * manifest.name|length }}