From 6a06579e133b132978b51c97564e46f2907b10b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Fri, 1 Sep 2023 09:44:09 +0200 Subject: [PATCH] Use Sphinx book theme for documentation --- .gitlab-ci.yml | 1 + .gitlab-scripts/check-template-modules.sh | 2 +- .gitlab-scripts/generate-doc.sh | 4 +++ .../.readthedocs.yaml | 7 +++++ .../doc/conf.py | 26 +++++++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/account/.readthedocs.yaml | 3 +++ modules/account/doc/conf.py | 20 ++++++++++++-- modules/account/doc/requirements-doc.txt | 2 ++ modules/account_asset/.readthedocs.yaml | 3 +++ modules/account_asset/doc/conf.py | 20 ++++++++++++-- .../account_asset/doc/requirements-doc.txt | 2 ++ modules/account_be/.readthedocs.yaml | 3 +++ modules/account_be/doc/conf.py | 20 ++++++++++++-- modules/account_be/doc/requirements-doc.txt | 2 ++ modules/account_budget/.readthedocs.yaml | 3 +++ modules/account_budget/doc/conf.py | 20 ++++++++++++-- .../account_budget/doc/requirements-doc.txt | 2 ++ .../account_cash_rounding/.readthedocs.yaml | 3 +++ modules/account_cash_rounding/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_consolidation/.readthedocs.yaml | 3 +++ modules/account_consolidation/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_credit_limit/.readthedocs.yaml | 3 +++ modules/account_credit_limit/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/account_de_skr03/.readthedocs.yaml | 3 +++ modules/account_de_skr03/doc/conf.py | 20 ++++++++++++-- .../account_de_skr03/doc/requirements-doc.txt | 2 ++ modules/account_deposit/.readthedocs.yaml | 3 +++ modules/account_deposit/doc/conf.py | 20 ++++++++++++-- .../account_deposit/doc/requirements-doc.txt | 2 ++ modules/account_dunning/.readthedocs.yaml | 3 +++ modules/account_dunning/doc/conf.py | 20 ++++++++++++-- .../account_dunning/doc/requirements-doc.txt | 2 ++ .../account_dunning_email/.readthedocs.yaml | 3 +++ modules/account_dunning_email/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/account_dunning_fee/.readthedocs.yaml | 3 +++ modules/account_dunning_fee/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_dunning_letter/.readthedocs.yaml | 3 +++ modules/account_dunning_letter/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/account_es/.readthedocs.yaml | 3 +++ modules/account_es/doc/conf.py | 20 ++++++++++++-- modules/account_es/doc/requirements-doc.txt | 2 ++ modules/account_es_sii/.readthedocs.yaml | 3 +++ modules/account_es_sii/doc/conf.py | 20 ++++++++++++-- .../account_es_sii/doc/requirements-doc.txt | 2 ++ modules/account_eu/.readthedocs.yaml | 3 +++ modules/account_eu/doc/conf.py | 20 ++++++++++++-- modules/account_eu/doc/requirements-doc.txt | 2 ++ modules/account_fr/.readthedocs.yaml | 3 +++ modules/account_fr/doc/conf.py | 20 ++++++++++++-- modules/account_fr/doc/requirements-doc.txt | 2 ++ modules/account_fr_chorus/.readthedocs.yaml | 3 +++ modules/account_fr_chorus/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/account_invoice/.readthedocs.yaml | 3 +++ modules/account_invoice/doc/conf.py | 20 ++++++++++++-- .../account_invoice/doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../account_invoice_correction/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_invoice_defer/.readthedocs.yaml | 3 +++ modules/account_invoice_defer/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_invoice_history/.readthedocs.yaml | 3 +++ modules/account_invoice_history/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_invoice_stock/.readthedocs.yaml | 3 +++ modules/account_invoice_stock/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/account_invoice_watermark/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../account_move_line_grouping/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/account_payment/.readthedocs.yaml | 3 +++ modules/account_payment/doc/conf.py | 20 ++++++++++++-- .../account_payment/doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/account_payment_braintree/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/account_payment_clearing/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_payment_sepa/.readthedocs.yaml | 3 +++ modules/account_payment_sepa/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../account_payment_sepa_cfonb/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_payment_stripe/.readthedocs.yaml | 3 +++ modules/account_payment_stripe/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/account_product/.readthedocs.yaml | 3 +++ modules/account_product/doc/conf.py | 20 ++++++++++++-- .../account_product/doc/requirements-doc.txt | 2 ++ .../account_receivable_rule/.readthedocs.yaml | 3 +++ modules/account_receivable_rule/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/account_rule/.readthedocs.yaml | 3 +++ modules/account_rule/doc/conf.py | 20 ++++++++++++-- modules/account_rule/doc/requirements-doc.txt | 2 ++ modules/account_statement/.readthedocs.yaml | 3 +++ modules/account_statement/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_statement_aeb43/.readthedocs.yaml | 3 +++ modules/account_statement_aeb43/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_statement_coda/.readthedocs.yaml | 3 +++ modules/account_statement_coda/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_statement_mt940/.readthedocs.yaml | 3 +++ modules/account_statement_mt940/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_statement_ofx/.readthedocs.yaml | 3 +++ modules/account_statement_ofx/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_statement_rule/.readthedocs.yaml | 3 +++ modules/account_statement_rule/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../account_statement_sepa/.readthedocs.yaml | 3 +++ modules/account_statement_sepa/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/account_stock_anglo_saxon/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/account_stock_continental/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/account_stock_eu/.readthedocs.yaml | 3 +++ modules/account_stock_eu/doc/conf.py | 20 ++++++++++++-- .../account_stock_eu/doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/account_stock_landed_cost/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../account_stock_shipment_cost/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/account_tax_cash/.readthedocs.yaml | 3 +++ modules/account_tax_cash/doc/conf.py | 20 ++++++++++++-- .../account_tax_cash/doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../account_tax_non_deductible/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/account_tax_rule_country/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/analytic_account/.readthedocs.yaml | 3 +++ modules/analytic_account/doc/conf.py | 20 ++++++++++++-- .../analytic_account/doc/requirements-doc.txt | 2 ++ modules/analytic_budget/.readthedocs.yaml | 3 +++ modules/analytic_budget/doc/conf.py | 20 ++++++++++++-- .../analytic_budget/doc/requirements-doc.txt | 2 ++ modules/analytic_invoice/.readthedocs.yaml | 3 +++ modules/analytic_invoice/doc/conf.py | 20 ++++++++++++-- .../analytic_invoice/doc/requirements-doc.txt | 2 ++ modules/analytic_purchase/.readthedocs.yaml | 3 +++ modules/analytic_purchase/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/analytic_sale/.readthedocs.yaml | 3 +++ modules/analytic_sale/doc/conf.py | 20 ++++++++++++-- .../analytic_sale/doc/requirements-doc.txt | 2 ++ modules/attendance/.readthedocs.yaml | 3 +++ modules/attendance/doc/conf.py | 20 ++++++++++++-- modules/attendance/doc/requirements-doc.txt | 2 ++ modules/authentication_saml/.readthedocs.yaml | 3 +++ modules/authentication_saml/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/authentication_sms/.readthedocs.yaml | 3 +++ modules/authentication_sms/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/bank/.readthedocs.yaml | 3 +++ modules/bank/doc/conf.py | 20 ++++++++++++-- modules/bank/doc/requirements-doc.txt | 2 ++ modules/carrier/.readthedocs.yaml | 3 +++ modules/carrier/doc/conf.py | 20 ++++++++++++-- modules/carrier/doc/requirements-doc.txt | 2 ++ modules/carrier_carriage/.readthedocs.yaml | 3 +++ modules/carrier_carriage/doc/conf.py | 20 ++++++++++++-- .../carrier_carriage/doc/requirements-doc.txt | 2 ++ modules/carrier_percentage/.readthedocs.yaml | 3 +++ modules/carrier_percentage/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/carrier_subdivision/.readthedocs.yaml | 3 +++ modules/carrier_subdivision/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/carrier_weight/.readthedocs.yaml | 3 +++ modules/carrier_weight/doc/conf.py | 20 ++++++++++++-- .../carrier_weight/doc/requirements-doc.txt | 2 ++ modules/commission/.readthedocs.yaml | 3 +++ modules/commission/doc/conf.py | 20 ++++++++++++-- modules/commission/doc/requirements-doc.txt | 2 ++ modules/commission_waiting/.readthedocs.yaml | 3 +++ modules/commission_waiting/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/company/.readthedocs.yaml | 3 +++ modules/company/doc/conf.py | 20 ++++++++++++-- modules/company/doc/requirements-doc.txt | 2 ++ modules/company_work_time/.readthedocs.yaml | 3 +++ modules/company_work_time/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/country/.readthedocs.yaml | 3 +++ modules/country/doc/conf.py | 20 ++++++++++++-- modules/country/doc/requirements-doc.txt | 2 ++ modules/currency/.readthedocs.yaml | 3 +++ modules/currency/doc/conf.py | 20 ++++++++++++-- modules/currency/doc/requirements-doc.txt | 2 ++ modules/currency_ro/.readthedocs.yaml | 3 +++ modules/currency_ro/doc/conf.py | 20 ++++++++++++-- modules/currency_ro/doc/requirements-doc.txt | 2 ++ modules/currency_rs/.readthedocs.yaml | 3 +++ modules/currency_rs/doc/conf.py | 20 ++++++++++++-- modules/currency_rs/doc/requirements-doc.txt | 2 ++ modules/customs/.readthedocs.yaml | 3 +++ modules/customs/doc/conf.py | 20 ++++++++++++-- modules/customs/doc/requirements-doc.txt | 2 ++ modules/dashboard/.readthedocs.yaml | 3 +++ modules/dashboard/doc/conf.py | 20 ++++++++++++-- modules/dashboard/doc/requirements-doc.txt | 2 ++ modules/edocument_uncefact/.readthedocs.yaml | 3 +++ modules/edocument_uncefact/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/edocument_unece/.readthedocs.yaml | 3 +++ modules/edocument_unece/doc/conf.py | 20 ++++++++++++-- .../edocument_unece/doc/requirements-doc.txt | 2 ++ modules/google_maps/.readthedocs.yaml | 3 +++ modules/google_maps/doc/conf.py | 20 ++++++++++++-- modules/google_maps/doc/requirements-doc.txt | 2 ++ modules/incoterm/.readthedocs.yaml | 3 +++ modules/incoterm/doc/conf.py | 20 ++++++++++++-- modules/incoterm/doc/requirements-doc.txt | 2 ++ modules/ldap_authentication/.readthedocs.yaml | 3 +++ modules/ldap_authentication/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/marketing/.readthedocs.yaml | 3 +++ modules/marketing/doc/conf.py | 20 ++++++++++++-- modules/marketing/doc/requirements-doc.txt | 2 ++ .../marketing_automation/.readthedocs.yaml | 3 +++ modules/marketing_automation/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/marketing_campaign/.readthedocs.yaml | 3 +++ modules/marketing_campaign/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/marketing_email/.readthedocs.yaml | 3 +++ modules/marketing_email/doc/conf.py | 20 ++++++++++++-- .../marketing_email/doc/requirements-doc.txt | 2 ++ modules/notification_email/.readthedocs.yaml | 3 +++ modules/notification_email/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/party/.readthedocs.yaml | 3 +++ modules/party/doc/conf.py | 20 ++++++++++++-- modules/party/doc/requirements-doc.txt | 2 ++ modules/party_avatar/.readthedocs.yaml | 3 +++ modules/party_avatar/doc/conf.py | 20 ++++++++++++-- modules/party_avatar/doc/requirements-doc.txt | 2 ++ modules/party_relationship/.readthedocs.yaml | 3 +++ modules/party_relationship/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/party_siret/.readthedocs.yaml | 3 +++ modules/party_siret/doc/conf.py | 20 ++++++++++++-- modules/party_siret/doc/requirements-doc.txt | 2 ++ modules/product/.readthedocs.yaml | 3 +++ modules/product/doc/conf.py | 20 ++++++++++++-- modules/product/doc/requirements-doc.txt | 2 ++ modules/product_attribute/.readthedocs.yaml | 3 +++ modules/product_attribute/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../product_classification/.readthedocs.yaml | 3 +++ modules/product_classification/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/product_cost_fifo/.readthedocs.yaml | 3 +++ modules/product_cost_fifo/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../product_cost_history/.readthedocs.yaml | 3 +++ modules/product_cost_history/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../product_cost_warehouse/.readthedocs.yaml | 3 +++ modules/product_cost_warehouse/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/product_image/.readthedocs.yaml | 3 +++ modules/product_image/doc/conf.py | 20 ++++++++++++-- .../product_image/doc/requirements-doc.txt | 2 ++ .../product_image_attribute/.readthedocs.yaml | 3 +++ modules/product_image_attribute/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/product_kit/.readthedocs.yaml | 3 +++ modules/product_kit/doc/conf.py | 20 ++++++++++++-- modules/product_kit/doc/requirements-doc.txt | 2 ++ .../product_measurements/.readthedocs.yaml | 3 +++ modules/product_measurements/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/product_price_list/.readthedocs.yaml | 3 +++ modules/product_price_list/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/product_price_list_cache/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/product_price_list_dates/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/product_price_list_parent/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/production/.readthedocs.yaml | 3 +++ modules/production/doc/conf.py | 20 ++++++++++++-- modules/production/doc/requirements-doc.txt | 2 ++ .../production_outsourcing/.readthedocs.yaml | 3 +++ modules/production_outsourcing/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/production_routing/.readthedocs.yaml | 3 +++ modules/production_routing/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/production_split/.readthedocs.yaml | 3 +++ modules/production_split/doc/conf.py | 20 ++++++++++++-- .../production_split/doc/requirements-doc.txt | 2 ++ modules/production_work/.readthedocs.yaml | 3 +++ modules/production_work/doc/conf.py | 20 ++++++++++++-- .../production_work/doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/production_work_timesheet/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/project/.readthedocs.yaml | 3 +++ modules/project/doc/conf.py | 20 ++++++++++++-- modules/project/doc/requirements-doc.txt | 2 ++ modules/project_invoice/.readthedocs.yaml | 3 +++ modules/project_invoice/doc/conf.py | 20 ++++++++++++-- .../project_invoice/doc/requirements-doc.txt | 2 ++ modules/project_plan/.readthedocs.yaml | 3 +++ modules/project_plan/doc/conf.py | 20 ++++++++++++-- modules/project_plan/doc/requirements-doc.txt | 2 ++ modules/project_revenue/.readthedocs.yaml | 3 +++ modules/project_revenue/doc/conf.py | 20 ++++++++++++-- .../project_revenue/doc/requirements-doc.txt | 2 ++ modules/purchase/.readthedocs.yaml | 3 +++ modules/purchase/doc/conf.py | 20 ++++++++++++-- modules/purchase/doc/requirements-doc.txt | 2 ++ modules/purchase_amendment/.readthedocs.yaml | 3 +++ modules/purchase_amendment/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../purchase_blanket_agreement/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/purchase_history/.readthedocs.yaml | 3 +++ modules/purchase_history/doc/conf.py | 20 ++++++++++++-- .../purchase_history/doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/purchase_price_list/.readthedocs.yaml | 3 +++ modules/purchase_price_list/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/purchase_product_quantity/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/purchase_request/.readthedocs.yaml | 3 +++ modules/purchase_request/doc/conf.py | 20 ++++++++++++-- .../purchase_request/doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../purchase_request_quotation/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../purchase_requisition/.readthedocs.yaml | 3 +++ modules/purchase_requisition/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../purchase_secondary_unit/.readthedocs.yaml | 3 +++ modules/purchase_secondary_unit/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../purchase_shipment_cost/.readthedocs.yaml | 3 +++ modules/purchase_shipment_cost/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/quality/.readthedocs.yaml | 3 +++ modules/quality/doc/conf.py | 20 ++++++++++++-- modules/quality/doc/requirements-doc.txt | 2 ++ modules/sale/.readthedocs.yaml | 3 +++ modules/sale/doc/conf.py | 20 ++++++++++++-- modules/sale/doc/requirements-doc.txt | 2 ++ .../sale_advance_payment/.readthedocs.yaml | 3 +++ modules/sale_advance_payment/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/sale_amendment/.readthedocs.yaml | 3 +++ modules/sale_amendment/doc/conf.py | 20 ++++++++++++-- .../sale_amendment/doc/requirements-doc.txt | 2 ++ .../sale_blanket_agreement/.readthedocs.yaml | 3 +++ modules/sale_blanket_agreement/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/sale_complaint/.readthedocs.yaml | 3 +++ modules/sale_complaint/doc/conf.py | 20 ++++++++++++-- .../sale_complaint/doc/requirements-doc.txt | 2 ++ modules/sale_credit_limit/.readthedocs.yaml | 3 +++ modules/sale_credit_limit/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/sale_discount/.readthedocs.yaml | 3 +++ modules/sale_discount/doc/conf.py | 20 ++++++++++++-- .../sale_discount/doc/requirements-doc.txt | 2 ++ modules/sale_extra/.readthedocs.yaml | 3 +++ modules/sale_extra/doc/conf.py | 20 ++++++++++++-- modules/sale_extra/doc/requirements-doc.txt | 2 ++ modules/sale_gift_card/.readthedocs.yaml | 3 +++ modules/sale_gift_card/doc/conf.py | 20 ++++++++++++-- .../sale_gift_card/doc/requirements-doc.txt | 2 ++ modules/sale_history/.readthedocs.yaml | 3 +++ modules/sale_history/doc/conf.py | 20 ++++++++++++-- modules/sale_history/doc/requirements-doc.txt | 2 ++ modules/sale_invoice_date/.readthedocs.yaml | 3 +++ modules/sale_invoice_date/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../sale_invoice_grouping/.readthedocs.yaml | 3 +++ modules/sale_invoice_grouping/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/sale_opportunity/.readthedocs.yaml | 3 +++ modules/sale_opportunity/doc/conf.py | 20 ++++++++++++-- .../sale_opportunity/doc/requirements-doc.txt | 2 ++ modules/sale_payment/.readthedocs.yaml | 3 +++ modules/sale_payment/doc/conf.py | 20 ++++++++++++-- modules/sale_payment/doc/requirements-doc.txt | 2 ++ modules/sale_point/.readthedocs.yaml | 3 +++ modules/sale_point/doc/conf.py | 20 ++++++++++++-- modules/sale_point/doc/requirements-doc.txt | 2 ++ modules/sale_price_list/.readthedocs.yaml | 3 +++ modules/sale_price_list/doc/conf.py | 20 ++++++++++++-- .../sale_price_list/doc/requirements-doc.txt | 2 ++ .../sale_product_customer/.readthedocs.yaml | 3 +++ modules/sale_product_customer/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../sale_product_quantity/.readthedocs.yaml | 3 +++ modules/sale_product_quantity/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../sale_product_recommendation/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/sale_promotion/.readthedocs.yaml | 3 +++ modules/sale_promotion/doc/conf.py | 20 ++++++++++++-- .../sale_promotion/doc/requirements-doc.txt | 2 ++ .../sale_promotion_coupon/.readthedocs.yaml | 3 +++ modules/sale_promotion_coupon/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../sale_promotion_coupon_payment/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/sale_secondary_unit/.readthedocs.yaml | 3 +++ modules/sale_secondary_unit/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/sale_shipment_cost/.readthedocs.yaml | 3 +++ modules/sale_shipment_cost/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../sale_shipment_grouping/.readthedocs.yaml | 3 +++ modules/sale_shipment_grouping/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../sale_shipment_tolerance/.readthedocs.yaml | 3 +++ modules/sale_shipment_tolerance/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/sale_stock_quantity/.readthedocs.yaml | 3 +++ modules/sale_stock_quantity/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/sale_subscription/.readthedocs.yaml | 3 +++ modules/sale_subscription/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../sale_subscription_asset/.readthedocs.yaml | 3 +++ modules/sale_subscription_asset/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/sale_supply/.readthedocs.yaml | 3 +++ modules/sale_supply/doc/conf.py | 20 ++++++++++++-- modules/sale_supply/doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/sale_supply_drop_shipment/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../sale_supply_production/.readthedocs.yaml | 3 +++ modules/sale_supply_production/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/stock/.readthedocs.yaml | 3 +++ modules/stock/doc/conf.py | 20 ++++++++++++-- modules/stock/doc/requirements-doc.txt | 2 ++ modules/stock_assign_manual/.readthedocs.yaml | 3 +++ modules/stock_assign_manual/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/stock_consignment/.readthedocs.yaml | 3 +++ modules/stock_consignment/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/stock_forecast/.readthedocs.yaml | 3 +++ modules/stock_forecast/doc/conf.py | 20 ++++++++++++-- .../stock_forecast/doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ modules/stock_inventory_location/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/stock_location_move/.readthedocs.yaml | 3 +++ modules/stock_location_move/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../stock_location_sequence/.readthedocs.yaml | 3 +++ modules/stock_location_sequence/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/stock_lot/.readthedocs.yaml | 3 +++ modules/stock_lot/doc/conf.py | 20 ++++++++++++-- modules/stock_lot/doc/requirements-doc.txt | 2 ++ modules/stock_lot_sled/.readthedocs.yaml | 3 +++ modules/stock_lot_sled/doc/conf.py | 20 ++++++++++++-- .../stock_lot_sled/doc/requirements-doc.txt | 2 ++ modules/stock_lot_unit/.readthedocs.yaml | 3 +++ modules/stock_lot_unit/doc/conf.py | 20 ++++++++++++-- .../stock_lot_unit/doc/requirements-doc.txt | 2 ++ modules/stock_package/.readthedocs.yaml | 3 +++ modules/stock_package/doc/conf.py | 20 ++++++++++++-- .../stock_package/doc/requirements-doc.txt | 2 ++ .../stock_package_shipping/.readthedocs.yaml | 3 +++ modules/stock_package_shipping/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../stock_package_shipping_dpd/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../stock_package_shipping_mygls/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../stock_package_shipping_ups/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../stock_product_location/.readthedocs.yaml | 3 +++ modules/stock_product_location/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../stock_quantity_early_planning/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../stock_quantity_issue/.readthedocs.yaml | 3 +++ modules/stock_quantity_issue/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../stock_secondary_unit/.readthedocs.yaml | 3 +++ modules/stock_secondary_unit/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/stock_shipment_cost/.readthedocs.yaml | 3 +++ modules/stock_shipment_cost/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../stock_shipment_cost_weight/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../stock_shipment_measurements/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/stock_split/.readthedocs.yaml | 3 +++ modules/stock_split/doc/conf.py | 20 ++++++++++++-- modules/stock_split/doc/requirements-doc.txt | 2 ++ modules/stock_supply/.readthedocs.yaml | 3 +++ modules/stock_supply/doc/conf.py | 20 ++++++++++++-- modules/stock_supply/doc/requirements-doc.txt | 2 ++ modules/stock_supply_day/.readthedocs.yaml | 3 +++ modules/stock_supply_day/doc/conf.py | 20 ++++++++++++-- .../stock_supply_day/doc/requirements-doc.txt | 2 ++ .../stock_supply_forecast/.readthedocs.yaml | 3 +++ modules/stock_supply_forecast/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../stock_supply_production/.readthedocs.yaml | 3 +++ modules/stock_supply_production/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/timesheet/.readthedocs.yaml | 3 +++ modules/timesheet/doc/conf.py | 20 ++++++++++++-- modules/timesheet/doc/requirements-doc.txt | 2 ++ modules/timesheet_cost/.readthedocs.yaml | 3 +++ modules/timesheet_cost/doc/conf.py | 20 ++++++++++++-- .../timesheet_cost/doc/requirements-doc.txt | 2 ++ modules/user_role/.readthedocs.yaml | 3 +++ modules/user_role/doc/conf.py | 20 ++++++++++++-- modules/user_role/doc/requirements-doc.txt | 2 ++ modules/web_shop/.readthedocs.yaml | 3 +++ modules/web_shop/doc/conf.py | 20 ++++++++++++-- modules/web_shop/doc/requirements-doc.txt | 2 ++ modules/web_shop_shopify/.readthedocs.yaml | 3 +++ modules/web_shop_shopify/doc/conf.py | 20 ++++++++++++-- .../web_shop_shopify/doc/requirements-doc.txt | 2 ++ .../web_shop_vue_storefront/.readthedocs.yaml | 3 +++ modules/web_shop_vue_storefront/doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ .../.readthedocs.yaml | 3 +++ .../doc/conf.py | 20 ++++++++++++-- .../doc/requirements-doc.txt | 2 ++ modules/web_shortener/.readthedocs.yaml | 3 +++ modules/web_shortener/doc/conf.py | 20 ++++++++++++-- .../web_shortener/doc/requirements-doc.txt | 2 ++ modules/web_user/.readthedocs.yaml | 3 +++ modules/web_user/doc/conf.py | 20 ++++++++++++-- modules/web_user/doc/requirements-doc.txt | 2 ++ proteus/.readthedocs.yaml | 3 +++ proteus/doc/conf.py | 20 ++++++++++++-- proteus/doc/requirements-doc.txt | 2 ++ readthedocs/.readthedocs.yaml | 3 +++ readthedocs/conf.py | 15 +++++++++++ readthedocs/requirements-doc.txt | 2 ++ tryton/.readthedocs.yaml | 3 +++ tryton/doc/conf.py | 20 ++++++++++++-- tryton/doc/requirements-doc.txt | 2 ++ trytond-gis/.readthedocs.yaml | 3 +++ trytond-gis/doc/conf.py | 20 ++++++++++++-- trytond-gis/doc/requirements-doc.txt | 2 ++ trytond/.readthedocs.yaml | 3 +++ trytond/doc/conf.py | 20 ++++++++++++-- trytond/doc/index.rst | 7 ----- trytond/doc/requirements-doc.txt | 2 ++ 619 files changed, 4728 insertions(+), 416 deletions(-) create mode 100644 cookiecutter-module/{{ cookiecutter.module_name }}/doc/requirements-doc.txt create mode 100644 modules/account/doc/requirements-doc.txt create mode 100644 modules/account_asset/doc/requirements-doc.txt create mode 100644 modules/account_be/doc/requirements-doc.txt create mode 100644 modules/account_budget/doc/requirements-doc.txt create mode 100644 modules/account_cash_rounding/doc/requirements-doc.txt create mode 100644 modules/account_consolidation/doc/requirements-doc.txt create mode 100644 modules/account_credit_limit/doc/requirements-doc.txt create mode 100644 modules/account_de_skr03/doc/requirements-doc.txt create mode 100644 modules/account_deposit/doc/requirements-doc.txt create mode 100644 modules/account_dunning/doc/requirements-doc.txt create mode 100644 modules/account_dunning_email/doc/requirements-doc.txt create mode 100644 modules/account_dunning_fee/doc/requirements-doc.txt create mode 100644 modules/account_dunning_letter/doc/requirements-doc.txt create mode 100644 modules/account_es/doc/requirements-doc.txt create mode 100644 modules/account_es_sii/doc/requirements-doc.txt create mode 100644 modules/account_eu/doc/requirements-doc.txt create mode 100644 modules/account_fr/doc/requirements-doc.txt create mode 100644 modules/account_fr_chorus/doc/requirements-doc.txt create mode 100644 modules/account_invoice/doc/requirements-doc.txt create mode 100644 modules/account_invoice_correction/doc/requirements-doc.txt create mode 100644 modules/account_invoice_defer/doc/requirements-doc.txt create mode 100644 modules/account_invoice_history/doc/requirements-doc.txt create mode 100644 modules/account_invoice_line_standalone/doc/requirements-doc.txt create mode 100644 modules/account_invoice_secondary_unit/doc/requirements-doc.txt create mode 100644 modules/account_invoice_stock/doc/requirements-doc.txt create mode 100644 modules/account_invoice_watermark/doc/requirements-doc.txt create mode 100644 modules/account_move_line_grouping/doc/requirements-doc.txt create mode 100644 modules/account_payment/doc/requirements-doc.txt create mode 100644 modules/account_payment_braintree/doc/requirements-doc.txt create mode 100644 modules/account_payment_clearing/doc/requirements-doc.txt create mode 100644 modules/account_payment_sepa/doc/requirements-doc.txt create mode 100644 modules/account_payment_sepa_cfonb/doc/requirements-doc.txt create mode 100644 modules/account_payment_stripe/doc/requirements-doc.txt create mode 100644 modules/account_product/doc/requirements-doc.txt create mode 100644 modules/account_receivable_rule/doc/requirements-doc.txt create mode 100644 modules/account_rule/doc/requirements-doc.txt create mode 100644 modules/account_statement/doc/requirements-doc.txt create mode 100644 modules/account_statement_aeb43/doc/requirements-doc.txt create mode 100644 modules/account_statement_coda/doc/requirements-doc.txt create mode 100644 modules/account_statement_mt940/doc/requirements-doc.txt create mode 100644 modules/account_statement_ofx/doc/requirements-doc.txt create mode 100644 modules/account_statement_rule/doc/requirements-doc.txt create mode 100644 modules/account_statement_sepa/doc/requirements-doc.txt create mode 100644 modules/account_stock_anglo_saxon/doc/requirements-doc.txt create mode 100644 modules/account_stock_continental/doc/requirements-doc.txt create mode 100644 modules/account_stock_eu/doc/requirements-doc.txt create mode 100644 modules/account_stock_landed_cost/doc/requirements-doc.txt create mode 100644 modules/account_stock_landed_cost_weight/doc/requirements-doc.txt create mode 100644 modules/account_stock_shipment_cost/doc/requirements-doc.txt create mode 100644 modules/account_stock_shipment_cost_weight/doc/requirements-doc.txt create mode 100644 modules/account_tax_cash/doc/requirements-doc.txt create mode 100644 modules/account_tax_non_deductible/doc/requirements-doc.txt create mode 100644 modules/account_tax_rule_country/doc/requirements-doc.txt create mode 100644 modules/analytic_account/doc/requirements-doc.txt create mode 100644 modules/analytic_budget/doc/requirements-doc.txt create mode 100644 modules/analytic_invoice/doc/requirements-doc.txt create mode 100644 modules/analytic_purchase/doc/requirements-doc.txt create mode 100644 modules/analytic_sale/doc/requirements-doc.txt create mode 100644 modules/attendance/doc/requirements-doc.txt create mode 100644 modules/authentication_saml/doc/requirements-doc.txt create mode 100644 modules/authentication_sms/doc/requirements-doc.txt create mode 100644 modules/bank/doc/requirements-doc.txt create mode 100644 modules/carrier/doc/requirements-doc.txt create mode 100644 modules/carrier_carriage/doc/requirements-doc.txt create mode 100644 modules/carrier_percentage/doc/requirements-doc.txt create mode 100644 modules/carrier_subdivision/doc/requirements-doc.txt create mode 100644 modules/carrier_weight/doc/requirements-doc.txt create mode 100644 modules/commission/doc/requirements-doc.txt create mode 100644 modules/commission_waiting/doc/requirements-doc.txt create mode 100644 modules/company/doc/requirements-doc.txt create mode 100644 modules/company_work_time/doc/requirements-doc.txt create mode 100644 modules/country/doc/requirements-doc.txt create mode 100644 modules/currency/doc/requirements-doc.txt create mode 100644 modules/currency_ro/doc/requirements-doc.txt create mode 100644 modules/currency_rs/doc/requirements-doc.txt create mode 100644 modules/customs/doc/requirements-doc.txt create mode 100644 modules/dashboard/doc/requirements-doc.txt create mode 100644 modules/edocument_uncefact/doc/requirements-doc.txt create mode 100644 modules/edocument_unece/doc/requirements-doc.txt create mode 100644 modules/google_maps/doc/requirements-doc.txt create mode 100644 modules/incoterm/doc/requirements-doc.txt create mode 100644 modules/ldap_authentication/doc/requirements-doc.txt create mode 100644 modules/marketing/doc/requirements-doc.txt create mode 100644 modules/marketing_automation/doc/requirements-doc.txt create mode 100644 modules/marketing_campaign/doc/requirements-doc.txt create mode 100644 modules/marketing_email/doc/requirements-doc.txt create mode 100644 modules/notification_email/doc/requirements-doc.txt create mode 100644 modules/party/doc/requirements-doc.txt create mode 100644 modules/party_avatar/doc/requirements-doc.txt create mode 100644 modules/party_relationship/doc/requirements-doc.txt create mode 100644 modules/party_siret/doc/requirements-doc.txt create mode 100644 modules/product/doc/requirements-doc.txt create mode 100644 modules/product_attribute/doc/requirements-doc.txt create mode 100644 modules/product_classification/doc/requirements-doc.txt create mode 100644 modules/product_classification_taxonomic/doc/requirements-doc.txt create mode 100644 modules/product_cost_fifo/doc/requirements-doc.txt create mode 100644 modules/product_cost_history/doc/requirements-doc.txt create mode 100644 modules/product_cost_warehouse/doc/requirements-doc.txt create mode 100644 modules/product_image/doc/requirements-doc.txt create mode 100644 modules/product_image_attribute/doc/requirements-doc.txt create mode 100644 modules/product_kit/doc/requirements-doc.txt create mode 100644 modules/product_measurements/doc/requirements-doc.txt create mode 100644 modules/product_price_list/doc/requirements-doc.txt create mode 100644 modules/product_price_list_cache/doc/requirements-doc.txt create mode 100644 modules/product_price_list_dates/doc/requirements-doc.txt create mode 100644 modules/product_price_list_parent/doc/requirements-doc.txt create mode 100644 modules/production/doc/requirements-doc.txt create mode 100644 modules/production_outsourcing/doc/requirements-doc.txt create mode 100644 modules/production_routing/doc/requirements-doc.txt create mode 100644 modules/production_split/doc/requirements-doc.txt create mode 100644 modules/production_work/doc/requirements-doc.txt create mode 100644 modules/production_work_timesheet/doc/requirements-doc.txt create mode 100644 modules/project/doc/requirements-doc.txt create mode 100644 modules/project_invoice/doc/requirements-doc.txt create mode 100644 modules/project_plan/doc/requirements-doc.txt create mode 100644 modules/project_revenue/doc/requirements-doc.txt create mode 100644 modules/purchase/doc/requirements-doc.txt create mode 100644 modules/purchase_amendment/doc/requirements-doc.txt create mode 100644 modules/purchase_blanket_agreement/doc/requirements-doc.txt create mode 100644 modules/purchase_history/doc/requirements-doc.txt create mode 100644 modules/purchase_invoice_line_standalone/doc/requirements-doc.txt create mode 100644 modules/purchase_price_list/doc/requirements-doc.txt create mode 100644 modules/purchase_product_quantity/doc/requirements-doc.txt create mode 100644 modules/purchase_request/doc/requirements-doc.txt create mode 100644 modules/purchase_request_quotation/doc/requirements-doc.txt create mode 100644 modules/purchase_requisition/doc/requirements-doc.txt create mode 100644 modules/purchase_secondary_unit/doc/requirements-doc.txt create mode 100644 modules/purchase_shipment_cost/doc/requirements-doc.txt create mode 100644 modules/quality/doc/requirements-doc.txt create mode 100644 modules/sale/doc/requirements-doc.txt create mode 100644 modules/sale_advance_payment/doc/requirements-doc.txt create mode 100644 modules/sale_amendment/doc/requirements-doc.txt create mode 100644 modules/sale_blanket_agreement/doc/requirements-doc.txt create mode 100644 modules/sale_complaint/doc/requirements-doc.txt create mode 100644 modules/sale_credit_limit/doc/requirements-doc.txt create mode 100644 modules/sale_discount/doc/requirements-doc.txt create mode 100644 modules/sale_extra/doc/requirements-doc.txt create mode 100644 modules/sale_gift_card/doc/requirements-doc.txt create mode 100644 modules/sale_history/doc/requirements-doc.txt create mode 100644 modules/sale_invoice_date/doc/requirements-doc.txt create mode 100644 modules/sale_invoice_grouping/doc/requirements-doc.txt create mode 100644 modules/sale_opportunity/doc/requirements-doc.txt create mode 100644 modules/sale_payment/doc/requirements-doc.txt create mode 100644 modules/sale_point/doc/requirements-doc.txt create mode 100644 modules/sale_price_list/doc/requirements-doc.txt create mode 100644 modules/sale_product_customer/doc/requirements-doc.txt create mode 100644 modules/sale_product_quantity/doc/requirements-doc.txt create mode 100644 modules/sale_product_recommendation/doc/requirements-doc.txt create mode 100644 modules/sale_product_recommendation_association_rule/doc/requirements-doc.txt create mode 100644 modules/sale_promotion/doc/requirements-doc.txt create mode 100644 modules/sale_promotion_coupon/doc/requirements-doc.txt create mode 100644 modules/sale_promotion_coupon_payment/doc/requirements-doc.txt create mode 100644 modules/sale_secondary_unit/doc/requirements-doc.txt create mode 100644 modules/sale_shipment_cost/doc/requirements-doc.txt create mode 100644 modules/sale_shipment_grouping/doc/requirements-doc.txt create mode 100644 modules/sale_shipment_tolerance/doc/requirements-doc.txt create mode 100644 modules/sale_stock_quantity/doc/requirements-doc.txt create mode 100644 modules/sale_subscription/doc/requirements-doc.txt create mode 100644 modules/sale_subscription_asset/doc/requirements-doc.txt create mode 100644 modules/sale_supply/doc/requirements-doc.txt create mode 100644 modules/sale_supply_drop_shipment/doc/requirements-doc.txt create mode 100644 modules/sale_supply_production/doc/requirements-doc.txt create mode 100644 modules/stock/doc/requirements-doc.txt create mode 100644 modules/stock_assign_manual/doc/requirements-doc.txt create mode 100644 modules/stock_consignment/doc/requirements-doc.txt create mode 100644 modules/stock_forecast/doc/requirements-doc.txt create mode 100644 modules/stock_inventory_location/doc/requirements-doc.txt create mode 100644 modules/stock_location_move/doc/requirements-doc.txt create mode 100644 modules/stock_location_sequence/doc/requirements-doc.txt create mode 100644 modules/stock_lot/doc/requirements-doc.txt create mode 100644 modules/stock_lot_sled/doc/requirements-doc.txt create mode 100644 modules/stock_lot_unit/doc/requirements-doc.txt create mode 100644 modules/stock_package/doc/requirements-doc.txt create mode 100644 modules/stock_package_shipping/doc/requirements-doc.txt create mode 100644 modules/stock_package_shipping_dpd/doc/requirements-doc.txt create mode 100644 modules/stock_package_shipping_mygls/doc/requirements-doc.txt create mode 100644 modules/stock_package_shipping_sendcloud/doc/requirements-doc.txt create mode 100644 modules/stock_package_shipping_ups/doc/requirements-doc.txt create mode 100644 modules/stock_product_location/doc/requirements-doc.txt create mode 100644 modules/stock_quantity_early_planning/doc/requirements-doc.txt create mode 100644 modules/stock_quantity_issue/doc/requirements-doc.txt create mode 100644 modules/stock_secondary_unit/doc/requirements-doc.txt create mode 100644 modules/stock_shipment_cost/doc/requirements-doc.txt create mode 100644 modules/stock_shipment_cost_weight/doc/requirements-doc.txt create mode 100644 modules/stock_shipment_measurements/doc/requirements-doc.txt create mode 100644 modules/stock_split/doc/requirements-doc.txt create mode 100644 modules/stock_supply/doc/requirements-doc.txt create mode 100644 modules/stock_supply_day/doc/requirements-doc.txt create mode 100644 modules/stock_supply_forecast/doc/requirements-doc.txt create mode 100644 modules/stock_supply_production/doc/requirements-doc.txt create mode 100644 modules/timesheet/doc/requirements-doc.txt create mode 100644 modules/timesheet_cost/doc/requirements-doc.txt create mode 100644 modules/user_role/doc/requirements-doc.txt create mode 100644 modules/web_shop/doc/requirements-doc.txt create mode 100644 modules/web_shop_shopify/doc/requirements-doc.txt create mode 100644 modules/web_shop_vue_storefront/doc/requirements-doc.txt create mode 100644 modules/web_shop_vue_storefront_stripe/doc/requirements-doc.txt create mode 100644 modules/web_shortener/doc/requirements-doc.txt create mode 100644 modules/web_user/doc/requirements-doc.txt create mode 100644 proteus/doc/requirements-doc.txt create mode 100644 readthedocs/requirements-doc.txt create mode 100644 tryton/doc/requirements-doc.txt create mode 100644 trytond-gis/doc/requirements-doc.txt create mode 100644 trytond/doc/requirements-doc.txt diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index e136b59c65..ffc736c063 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -57,6 +57,7 @@ documentation: paths: - .cache/pip/http before_script: + - pip install -r "${PACKAGE}/${DOC_DIR}/requirements-doc.txt" - pip install sphinx-lint rstcheck[sphinx] script: - cd "${PACKAGE}" diff --git a/.gitlab-scripts/check-template-modules.sh b/.gitlab-scripts/check-template-modules.sh index 9935b3d4ec..6452ecc38b 100755 --- a/.gitlab-scripts/check-template-modules.sh +++ b/.gitlab-scripts/check-template-modules.sh @@ -8,7 +8,7 @@ do module=`basename "${path}"` printf "Check $module ... " cookiecutter --no-input cookiecutter-module -o "${OUTPUT}" module_name="${module}" - for file in tox.ini .readthedocs.yaml doc/conf.py + for file in tox.ini .readthedocs.yaml doc/conf.py doc/requirements-doc.txt do cmp "${path}/${file}" "${OUTPUT}/${module}/${file}" done diff --git a/.gitlab-scripts/generate-doc.sh b/.gitlab-scripts/generate-doc.sh index 69f1f43ed2..d3602204ae 100755 --- a/.gitlab-scripts/generate-doc.sh +++ b/.gitlab-scripts/generate-doc.sh @@ -5,6 +5,10 @@ OUTPUTDIR=`realpath "${1}"` mkdir -p "${OUTPUTDIR}" export DOC_BASE_URL=$OUTPUTDIR +find . -name 'cookiecutter*' -prune -o -path '*/doc/requirements-doc.txt' -print | while read path; do + pip install -r "${path}" +done + (find . -name 'cookiecutter*' -prune -o -path '*/doc/conf.py' -print | while read path; do path=`dirname "${path}"` path=`dirname "${path}"` diff --git a/cookiecutter-module/{{ cookiecutter.module_name }}/.readthedocs.yaml b/cookiecutter-module/{{ cookiecutter.module_name }}/.readthedocs.yaml index 5476f707e8..e9b672f0d9 100644 --- a/cookiecutter-module/{{ cookiecutter.module_name }}/.readthedocs.yaml +++ b/cookiecutter-module/{{ cookiecutter.module_name }}/.readthedocs.yaml @@ -3,6 +3,13 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + {%- if not cookiecutter.prefix %} + - requirements: modules/{{ cookiecutter.package_name }}/doc/requirements-doc.txt + {%- else %} + - requirements: doc/requirements-doc.txt + {%- endif %} sphinx: {%- if not cookiecutter.prefix %} configuration: modules/{{ cookiecutter.module_name }}/doc/conf.py diff --git a/cookiecutter-module/{{ cookiecutter.module_name }}/doc/conf.py b/cookiecutter-module/{{ cookiecutter.module_name }}/doc/conf.py index 6216ed01b0..c0cfbf6206 100644 --- a/cookiecutter-module/{{ cookiecutter.module_name }}/doc/conf.py +++ b/cookiecutter-module/{{ cookiecutter.module_name }}/doc/conf.py @@ -27,9 +27,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -40,8 +41,14 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + {%- if not cookiecutter.prefix %} + info['branch'] = 'branch/default' + {%- endif %} else: info['series'] = '.'.join(version.split('.', 2)[:2]) + {%- if not cookiecutter.prefix %} + info['branch'] = 'branch/' + info['series'] + {%- endif %} for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -53,12 +60,27 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +{%- if not cookiecutter.prefix %} +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/{{ cookiecutter.module_name }}/doc', + } +{%- endif %} +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/cookiecutter-module/{{ cookiecutter.module_name }}/doc/requirements-doc.txt b/cookiecutter-module/{{ cookiecutter.module_name }}/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/cookiecutter-module/{{ cookiecutter.module_name }}/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account/.readthedocs.yaml b/modules/account/.readthedocs.yaml index ba89777bc6..113cad919c 100644 --- a/modules/account/.readthedocs.yaml +++ b/modules/account/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account/doc/requirements-doc.txt sphinx: configuration: modules/account/doc/conf.py diff --git a/modules/account/doc/conf.py b/modules/account/doc/conf.py index 540e9c3069..b6cf348991 100644 --- a/modules/account/doc/conf.py +++ b/modules/account/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account/doc/requirements-doc.txt b/modules/account/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_asset/.readthedocs.yaml b/modules/account_asset/.readthedocs.yaml index adffff5e51..1f07542b5c 100644 --- a/modules/account_asset/.readthedocs.yaml +++ b/modules/account_asset/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_asset/doc/requirements-doc.txt sphinx: configuration: modules/account_asset/doc/conf.py diff --git a/modules/account_asset/doc/conf.py b/modules/account_asset/doc/conf.py index 540e9c3069..17ff54eb61 100644 --- a/modules/account_asset/doc/conf.py +++ b/modules/account_asset/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_asset/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_asset/doc/requirements-doc.txt b/modules/account_asset/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_asset/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_be/.readthedocs.yaml b/modules/account_be/.readthedocs.yaml index 736db1c219..b8c18f8158 100644 --- a/modules/account_be/.readthedocs.yaml +++ b/modules/account_be/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_be/doc/requirements-doc.txt sphinx: configuration: modules/account_be/doc/conf.py diff --git a/modules/account_be/doc/conf.py b/modules/account_be/doc/conf.py index 540e9c3069..75f7a64ec0 100644 --- a/modules/account_be/doc/conf.py +++ b/modules/account_be/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_be/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_be/doc/requirements-doc.txt b/modules/account_be/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_be/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_budget/.readthedocs.yaml b/modules/account_budget/.readthedocs.yaml index ba823519c7..bdee0dbc9e 100644 --- a/modules/account_budget/.readthedocs.yaml +++ b/modules/account_budget/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_budget/doc/requirements-doc.txt sphinx: configuration: modules/account_budget/doc/conf.py diff --git a/modules/account_budget/doc/conf.py b/modules/account_budget/doc/conf.py index 540e9c3069..63f9db4795 100644 --- a/modules/account_budget/doc/conf.py +++ b/modules/account_budget/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_budget/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_budget/doc/requirements-doc.txt b/modules/account_budget/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_budget/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_cash_rounding/.readthedocs.yaml b/modules/account_cash_rounding/.readthedocs.yaml index 6c828b6309..5747d961de 100644 --- a/modules/account_cash_rounding/.readthedocs.yaml +++ b/modules/account_cash_rounding/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_cash_rounding/doc/requirements-doc.txt sphinx: configuration: modules/account_cash_rounding/doc/conf.py diff --git a/modules/account_cash_rounding/doc/conf.py b/modules/account_cash_rounding/doc/conf.py index 540e9c3069..c270ffc298 100644 --- a/modules/account_cash_rounding/doc/conf.py +++ b/modules/account_cash_rounding/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_cash_rounding/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_cash_rounding/doc/requirements-doc.txt b/modules/account_cash_rounding/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_cash_rounding/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_consolidation/.readthedocs.yaml b/modules/account_consolidation/.readthedocs.yaml index 0623db172f..c27cd5f25b 100644 --- a/modules/account_consolidation/.readthedocs.yaml +++ b/modules/account_consolidation/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_consolidation/doc/requirements-doc.txt sphinx: configuration: modules/account_consolidation/doc/conf.py diff --git a/modules/account_consolidation/doc/conf.py b/modules/account_consolidation/doc/conf.py index 540e9c3069..466cbb0b2f 100644 --- a/modules/account_consolidation/doc/conf.py +++ b/modules/account_consolidation/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_consolidation/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_consolidation/doc/requirements-doc.txt b/modules/account_consolidation/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_consolidation/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_credit_limit/.readthedocs.yaml b/modules/account_credit_limit/.readthedocs.yaml index 94fac8fb9d..b28d5b1196 100644 --- a/modules/account_credit_limit/.readthedocs.yaml +++ b/modules/account_credit_limit/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_credit_limit/doc/requirements-doc.txt sphinx: configuration: modules/account_credit_limit/doc/conf.py diff --git a/modules/account_credit_limit/doc/conf.py b/modules/account_credit_limit/doc/conf.py index 540e9c3069..470e146a95 100644 --- a/modules/account_credit_limit/doc/conf.py +++ b/modules/account_credit_limit/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_credit_limit/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_credit_limit/doc/requirements-doc.txt b/modules/account_credit_limit/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_credit_limit/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_de_skr03/.readthedocs.yaml b/modules/account_de_skr03/.readthedocs.yaml index 63396bc8b1..c492634fd2 100644 --- a/modules/account_de_skr03/.readthedocs.yaml +++ b/modules/account_de_skr03/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_de_skr03/doc/requirements-doc.txt sphinx: configuration: modules/account_de_skr03/doc/conf.py diff --git a/modules/account_de_skr03/doc/conf.py b/modules/account_de_skr03/doc/conf.py index 540e9c3069..f6def39458 100644 --- a/modules/account_de_skr03/doc/conf.py +++ b/modules/account_de_skr03/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_de_skr03/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_de_skr03/doc/requirements-doc.txt b/modules/account_de_skr03/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_de_skr03/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_deposit/.readthedocs.yaml b/modules/account_deposit/.readthedocs.yaml index 284b10c43e..6cba357ca5 100644 --- a/modules/account_deposit/.readthedocs.yaml +++ b/modules/account_deposit/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_deposit/doc/requirements-doc.txt sphinx: configuration: modules/account_deposit/doc/conf.py diff --git a/modules/account_deposit/doc/conf.py b/modules/account_deposit/doc/conf.py index 540e9c3069..c39ef0b722 100644 --- a/modules/account_deposit/doc/conf.py +++ b/modules/account_deposit/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_deposit/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_deposit/doc/requirements-doc.txt b/modules/account_deposit/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_deposit/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_dunning/.readthedocs.yaml b/modules/account_dunning/.readthedocs.yaml index d39731a847..3d0df30f92 100644 --- a/modules/account_dunning/.readthedocs.yaml +++ b/modules/account_dunning/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_dunning/doc/requirements-doc.txt sphinx: configuration: modules/account_dunning/doc/conf.py diff --git a/modules/account_dunning/doc/conf.py b/modules/account_dunning/doc/conf.py index 540e9c3069..fdea85ee03 100644 --- a/modules/account_dunning/doc/conf.py +++ b/modules/account_dunning/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_dunning/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_dunning/doc/requirements-doc.txt b/modules/account_dunning/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_dunning/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_dunning_email/.readthedocs.yaml b/modules/account_dunning_email/.readthedocs.yaml index a9a1026376..42b722fee5 100644 --- a/modules/account_dunning_email/.readthedocs.yaml +++ b/modules/account_dunning_email/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_dunning_email/doc/requirements-doc.txt sphinx: configuration: modules/account_dunning_email/doc/conf.py diff --git a/modules/account_dunning_email/doc/conf.py b/modules/account_dunning_email/doc/conf.py index 540e9c3069..126e4de94b 100644 --- a/modules/account_dunning_email/doc/conf.py +++ b/modules/account_dunning_email/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_dunning_email/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_dunning_email/doc/requirements-doc.txt b/modules/account_dunning_email/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_dunning_email/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_dunning_fee/.readthedocs.yaml b/modules/account_dunning_fee/.readthedocs.yaml index 20e6c2bd42..a12c828391 100644 --- a/modules/account_dunning_fee/.readthedocs.yaml +++ b/modules/account_dunning_fee/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_dunning_fee/doc/requirements-doc.txt sphinx: configuration: modules/account_dunning_fee/doc/conf.py diff --git a/modules/account_dunning_fee/doc/conf.py b/modules/account_dunning_fee/doc/conf.py index 540e9c3069..66b1e7461f 100644 --- a/modules/account_dunning_fee/doc/conf.py +++ b/modules/account_dunning_fee/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_dunning_fee/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_dunning_fee/doc/requirements-doc.txt b/modules/account_dunning_fee/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_dunning_fee/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_dunning_letter/.readthedocs.yaml b/modules/account_dunning_letter/.readthedocs.yaml index 81ca945791..353963e169 100644 --- a/modules/account_dunning_letter/.readthedocs.yaml +++ b/modules/account_dunning_letter/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_dunning_letter/doc/requirements-doc.txt sphinx: configuration: modules/account_dunning_letter/doc/conf.py diff --git a/modules/account_dunning_letter/doc/conf.py b/modules/account_dunning_letter/doc/conf.py index 540e9c3069..d7382f3d85 100644 --- a/modules/account_dunning_letter/doc/conf.py +++ b/modules/account_dunning_letter/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_dunning_letter/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_dunning_letter/doc/requirements-doc.txt b/modules/account_dunning_letter/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_dunning_letter/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_es/.readthedocs.yaml b/modules/account_es/.readthedocs.yaml index f37394cd90..7b7a067dd4 100644 --- a/modules/account_es/.readthedocs.yaml +++ b/modules/account_es/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_es/doc/requirements-doc.txt sphinx: configuration: modules/account_es/doc/conf.py diff --git a/modules/account_es/doc/conf.py b/modules/account_es/doc/conf.py index 540e9c3069..216fca8850 100644 --- a/modules/account_es/doc/conf.py +++ b/modules/account_es/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_es/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_es/doc/requirements-doc.txt b/modules/account_es/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_es/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_es_sii/.readthedocs.yaml b/modules/account_es_sii/.readthedocs.yaml index 9bfeb37c2c..cd7975ae4f 100644 --- a/modules/account_es_sii/.readthedocs.yaml +++ b/modules/account_es_sii/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_es_sii/doc/requirements-doc.txt sphinx: configuration: modules/account_es_sii/doc/conf.py diff --git a/modules/account_es_sii/doc/conf.py b/modules/account_es_sii/doc/conf.py index 540e9c3069..95b2a5ef1f 100644 --- a/modules/account_es_sii/doc/conf.py +++ b/modules/account_es_sii/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_es_sii/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_es_sii/doc/requirements-doc.txt b/modules/account_es_sii/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_es_sii/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_eu/.readthedocs.yaml b/modules/account_eu/.readthedocs.yaml index ac3cdb4905..4295804298 100644 --- a/modules/account_eu/.readthedocs.yaml +++ b/modules/account_eu/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_eu/doc/requirements-doc.txt sphinx: configuration: modules/account_eu/doc/conf.py diff --git a/modules/account_eu/doc/conf.py b/modules/account_eu/doc/conf.py index 540e9c3069..fbfaa63c67 100644 --- a/modules/account_eu/doc/conf.py +++ b/modules/account_eu/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_eu/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_eu/doc/requirements-doc.txt b/modules/account_eu/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_eu/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_fr/.readthedocs.yaml b/modules/account_fr/.readthedocs.yaml index a8690aab9b..41ef4666cf 100644 --- a/modules/account_fr/.readthedocs.yaml +++ b/modules/account_fr/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_fr/doc/requirements-doc.txt sphinx: configuration: modules/account_fr/doc/conf.py diff --git a/modules/account_fr/doc/conf.py b/modules/account_fr/doc/conf.py index 540e9c3069..d2828fb3c4 100644 --- a/modules/account_fr/doc/conf.py +++ b/modules/account_fr/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_fr/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_fr/doc/requirements-doc.txt b/modules/account_fr/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_fr/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_fr_chorus/.readthedocs.yaml b/modules/account_fr_chorus/.readthedocs.yaml index 538f5c2d12..0a8c814513 100644 --- a/modules/account_fr_chorus/.readthedocs.yaml +++ b/modules/account_fr_chorus/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_fr_chorus/doc/requirements-doc.txt sphinx: configuration: modules/account_fr_chorus/doc/conf.py diff --git a/modules/account_fr_chorus/doc/conf.py b/modules/account_fr_chorus/doc/conf.py index 540e9c3069..faeacbb688 100644 --- a/modules/account_fr_chorus/doc/conf.py +++ b/modules/account_fr_chorus/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_fr_chorus/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_fr_chorus/doc/requirements-doc.txt b/modules/account_fr_chorus/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_fr_chorus/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_invoice/.readthedocs.yaml b/modules/account_invoice/.readthedocs.yaml index cebbd6d842..acfa099869 100644 --- a/modules/account_invoice/.readthedocs.yaml +++ b/modules/account_invoice/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_invoice/doc/requirements-doc.txt sphinx: configuration: modules/account_invoice/doc/conf.py diff --git a/modules/account_invoice/doc/conf.py b/modules/account_invoice/doc/conf.py index 540e9c3069..3756e99943 100644 --- a/modules/account_invoice/doc/conf.py +++ b/modules/account_invoice/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_invoice/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_invoice/doc/requirements-doc.txt b/modules/account_invoice/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_invoice/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_invoice_correction/.readthedocs.yaml b/modules/account_invoice_correction/.readthedocs.yaml index 7c304ed4b0..2cf418ecb8 100644 --- a/modules/account_invoice_correction/.readthedocs.yaml +++ b/modules/account_invoice_correction/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_invoice_correction/doc/requirements-doc.txt sphinx: configuration: modules/account_invoice_correction/doc/conf.py diff --git a/modules/account_invoice_correction/doc/conf.py b/modules/account_invoice_correction/doc/conf.py index 540e9c3069..188e62a99f 100644 --- a/modules/account_invoice_correction/doc/conf.py +++ b/modules/account_invoice_correction/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_invoice_correction/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_invoice_correction/doc/requirements-doc.txt b/modules/account_invoice_correction/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_invoice_correction/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_invoice_defer/.readthedocs.yaml b/modules/account_invoice_defer/.readthedocs.yaml index 5dccd87511..bbadd5262b 100644 --- a/modules/account_invoice_defer/.readthedocs.yaml +++ b/modules/account_invoice_defer/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_invoice_defer/doc/requirements-doc.txt sphinx: configuration: modules/account_invoice_defer/doc/conf.py diff --git a/modules/account_invoice_defer/doc/conf.py b/modules/account_invoice_defer/doc/conf.py index 540e9c3069..09982b0135 100644 --- a/modules/account_invoice_defer/doc/conf.py +++ b/modules/account_invoice_defer/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_invoice_defer/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_invoice_defer/doc/requirements-doc.txt b/modules/account_invoice_defer/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_invoice_defer/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_invoice_history/.readthedocs.yaml b/modules/account_invoice_history/.readthedocs.yaml index 0a02a65c3d..8021cf6527 100644 --- a/modules/account_invoice_history/.readthedocs.yaml +++ b/modules/account_invoice_history/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_invoice_history/doc/requirements-doc.txt sphinx: configuration: modules/account_invoice_history/doc/conf.py diff --git a/modules/account_invoice_history/doc/conf.py b/modules/account_invoice_history/doc/conf.py index 540e9c3069..a19d1e5ad5 100644 --- a/modules/account_invoice_history/doc/conf.py +++ b/modules/account_invoice_history/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_invoice_history/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_invoice_history/doc/requirements-doc.txt b/modules/account_invoice_history/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_invoice_history/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_invoice_line_standalone/.readthedocs.yaml b/modules/account_invoice_line_standalone/.readthedocs.yaml index d97f97a3e2..35ecf8874a 100644 --- a/modules/account_invoice_line_standalone/.readthedocs.yaml +++ b/modules/account_invoice_line_standalone/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_invoice_line_standalone/doc/requirements-doc.txt sphinx: configuration: modules/account_invoice_line_standalone/doc/conf.py diff --git a/modules/account_invoice_line_standalone/doc/conf.py b/modules/account_invoice_line_standalone/doc/conf.py index 540e9c3069..94e41ddf04 100644 --- a/modules/account_invoice_line_standalone/doc/conf.py +++ b/modules/account_invoice_line_standalone/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_invoice_line_standalone/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_invoice_line_standalone/doc/requirements-doc.txt b/modules/account_invoice_line_standalone/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_invoice_line_standalone/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_invoice_secondary_unit/.readthedocs.yaml b/modules/account_invoice_secondary_unit/.readthedocs.yaml index c3fc7bec3b..db01a87114 100644 --- a/modules/account_invoice_secondary_unit/.readthedocs.yaml +++ b/modules/account_invoice_secondary_unit/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_invoice_secondary_unit/doc/requirements-doc.txt sphinx: configuration: modules/account_invoice_secondary_unit/doc/conf.py diff --git a/modules/account_invoice_secondary_unit/doc/conf.py b/modules/account_invoice_secondary_unit/doc/conf.py index 540e9c3069..42fb0fea96 100644 --- a/modules/account_invoice_secondary_unit/doc/conf.py +++ b/modules/account_invoice_secondary_unit/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_invoice_secondary_unit/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_invoice_secondary_unit/doc/requirements-doc.txt b/modules/account_invoice_secondary_unit/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_invoice_secondary_unit/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_invoice_stock/.readthedocs.yaml b/modules/account_invoice_stock/.readthedocs.yaml index 68afb91cbe..5885632a90 100644 --- a/modules/account_invoice_stock/.readthedocs.yaml +++ b/modules/account_invoice_stock/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_invoice_stock/doc/requirements-doc.txt sphinx: configuration: modules/account_invoice_stock/doc/conf.py diff --git a/modules/account_invoice_stock/doc/conf.py b/modules/account_invoice_stock/doc/conf.py index 540e9c3069..a65e2d584c 100644 --- a/modules/account_invoice_stock/doc/conf.py +++ b/modules/account_invoice_stock/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_invoice_stock/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_invoice_stock/doc/requirements-doc.txt b/modules/account_invoice_stock/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_invoice_stock/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_invoice_watermark/.readthedocs.yaml b/modules/account_invoice_watermark/.readthedocs.yaml index cd09df9ea6..5c4eafaaca 100644 --- a/modules/account_invoice_watermark/.readthedocs.yaml +++ b/modules/account_invoice_watermark/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_invoice_watermark/doc/requirements-doc.txt sphinx: configuration: modules/account_invoice_watermark/doc/conf.py diff --git a/modules/account_invoice_watermark/doc/conf.py b/modules/account_invoice_watermark/doc/conf.py index 540e9c3069..58c98036c1 100644 --- a/modules/account_invoice_watermark/doc/conf.py +++ b/modules/account_invoice_watermark/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_invoice_watermark/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_invoice_watermark/doc/requirements-doc.txt b/modules/account_invoice_watermark/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_invoice_watermark/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_move_line_grouping/.readthedocs.yaml b/modules/account_move_line_grouping/.readthedocs.yaml index a037cd2018..ff65c6f5ce 100644 --- a/modules/account_move_line_grouping/.readthedocs.yaml +++ b/modules/account_move_line_grouping/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_move_line_grouping/doc/requirements-doc.txt sphinx: configuration: modules/account_move_line_grouping/doc/conf.py diff --git a/modules/account_move_line_grouping/doc/conf.py b/modules/account_move_line_grouping/doc/conf.py index 540e9c3069..d95cb85279 100644 --- a/modules/account_move_line_grouping/doc/conf.py +++ b/modules/account_move_line_grouping/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_move_line_grouping/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_move_line_grouping/doc/requirements-doc.txt b/modules/account_move_line_grouping/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_move_line_grouping/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_payment/.readthedocs.yaml b/modules/account_payment/.readthedocs.yaml index 476ee9b589..085e28d09c 100644 --- a/modules/account_payment/.readthedocs.yaml +++ b/modules/account_payment/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_payment/doc/requirements-doc.txt sphinx: configuration: modules/account_payment/doc/conf.py diff --git a/modules/account_payment/doc/conf.py b/modules/account_payment/doc/conf.py index 540e9c3069..a17a1e4d27 100644 --- a/modules/account_payment/doc/conf.py +++ b/modules/account_payment/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_payment/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_payment/doc/requirements-doc.txt b/modules/account_payment/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_payment/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_payment_braintree/.readthedocs.yaml b/modules/account_payment_braintree/.readthedocs.yaml index 23065f280d..b8f3be3111 100644 --- a/modules/account_payment_braintree/.readthedocs.yaml +++ b/modules/account_payment_braintree/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_payment_braintree/doc/requirements-doc.txt sphinx: configuration: modules/account_payment_braintree/doc/conf.py diff --git a/modules/account_payment_braintree/doc/conf.py b/modules/account_payment_braintree/doc/conf.py index 540e9c3069..dbaca633ac 100644 --- a/modules/account_payment_braintree/doc/conf.py +++ b/modules/account_payment_braintree/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_payment_braintree/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_payment_braintree/doc/requirements-doc.txt b/modules/account_payment_braintree/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_payment_braintree/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_payment_clearing/.readthedocs.yaml b/modules/account_payment_clearing/.readthedocs.yaml index 1a5732ceb0..8f0dbaf27b 100644 --- a/modules/account_payment_clearing/.readthedocs.yaml +++ b/modules/account_payment_clearing/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_payment_clearing/doc/requirements-doc.txt sphinx: configuration: modules/account_payment_clearing/doc/conf.py diff --git a/modules/account_payment_clearing/doc/conf.py b/modules/account_payment_clearing/doc/conf.py index 540e9c3069..ae95119e32 100644 --- a/modules/account_payment_clearing/doc/conf.py +++ b/modules/account_payment_clearing/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_payment_clearing/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_payment_clearing/doc/requirements-doc.txt b/modules/account_payment_clearing/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_payment_clearing/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_payment_sepa/.readthedocs.yaml b/modules/account_payment_sepa/.readthedocs.yaml index c903e09172..46076b7b69 100644 --- a/modules/account_payment_sepa/.readthedocs.yaml +++ b/modules/account_payment_sepa/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_payment_sepa/doc/requirements-doc.txt sphinx: configuration: modules/account_payment_sepa/doc/conf.py diff --git a/modules/account_payment_sepa/doc/conf.py b/modules/account_payment_sepa/doc/conf.py index 540e9c3069..5a3d717809 100644 --- a/modules/account_payment_sepa/doc/conf.py +++ b/modules/account_payment_sepa/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_payment_sepa/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_payment_sepa/doc/requirements-doc.txt b/modules/account_payment_sepa/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_payment_sepa/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_payment_sepa_cfonb/.readthedocs.yaml b/modules/account_payment_sepa_cfonb/.readthedocs.yaml index 9e63058eca..5836cbd5ed 100644 --- a/modules/account_payment_sepa_cfonb/.readthedocs.yaml +++ b/modules/account_payment_sepa_cfonb/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_payment_sepa_cfonb/doc/requirements-doc.txt sphinx: configuration: modules/account_payment_sepa_cfonb/doc/conf.py diff --git a/modules/account_payment_sepa_cfonb/doc/conf.py b/modules/account_payment_sepa_cfonb/doc/conf.py index 540e9c3069..c8487b9722 100644 --- a/modules/account_payment_sepa_cfonb/doc/conf.py +++ b/modules/account_payment_sepa_cfonb/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_payment_sepa_cfonb/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_payment_sepa_cfonb/doc/requirements-doc.txt b/modules/account_payment_sepa_cfonb/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_payment_sepa_cfonb/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_payment_stripe/.readthedocs.yaml b/modules/account_payment_stripe/.readthedocs.yaml index 8939f72c2f..f6e51a4368 100644 --- a/modules/account_payment_stripe/.readthedocs.yaml +++ b/modules/account_payment_stripe/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_payment_stripe/doc/requirements-doc.txt sphinx: configuration: modules/account_payment_stripe/doc/conf.py diff --git a/modules/account_payment_stripe/doc/conf.py b/modules/account_payment_stripe/doc/conf.py index 540e9c3069..aa5a7906c8 100644 --- a/modules/account_payment_stripe/doc/conf.py +++ b/modules/account_payment_stripe/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_payment_stripe/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_payment_stripe/doc/requirements-doc.txt b/modules/account_payment_stripe/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_payment_stripe/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_product/.readthedocs.yaml b/modules/account_product/.readthedocs.yaml index 5ffd99592a..42ac6b2a0e 100644 --- a/modules/account_product/.readthedocs.yaml +++ b/modules/account_product/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_product/doc/requirements-doc.txt sphinx: configuration: modules/account_product/doc/conf.py diff --git a/modules/account_product/doc/conf.py b/modules/account_product/doc/conf.py index 540e9c3069..b4dc002836 100644 --- a/modules/account_product/doc/conf.py +++ b/modules/account_product/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_product/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_product/doc/requirements-doc.txt b/modules/account_product/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_product/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_receivable_rule/.readthedocs.yaml b/modules/account_receivable_rule/.readthedocs.yaml index 92bd0fa7d8..1ae16d7088 100644 --- a/modules/account_receivable_rule/.readthedocs.yaml +++ b/modules/account_receivable_rule/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_receivable_rule/doc/requirements-doc.txt sphinx: configuration: modules/account_receivable_rule/doc/conf.py diff --git a/modules/account_receivable_rule/doc/conf.py b/modules/account_receivable_rule/doc/conf.py index 540e9c3069..affcd36f3a 100644 --- a/modules/account_receivable_rule/doc/conf.py +++ b/modules/account_receivable_rule/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_receivable_rule/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_receivable_rule/doc/requirements-doc.txt b/modules/account_receivable_rule/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_receivable_rule/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_rule/.readthedocs.yaml b/modules/account_rule/.readthedocs.yaml index f6ed2c18eb..b8feb8a166 100644 --- a/modules/account_rule/.readthedocs.yaml +++ b/modules/account_rule/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_rule/doc/requirements-doc.txt sphinx: configuration: modules/account_rule/doc/conf.py diff --git a/modules/account_rule/doc/conf.py b/modules/account_rule/doc/conf.py index 540e9c3069..3bcc34ffda 100644 --- a/modules/account_rule/doc/conf.py +++ b/modules/account_rule/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_rule/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_rule/doc/requirements-doc.txt b/modules/account_rule/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_rule/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_statement/.readthedocs.yaml b/modules/account_statement/.readthedocs.yaml index 2bae993630..652d670056 100644 --- a/modules/account_statement/.readthedocs.yaml +++ b/modules/account_statement/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_statement/doc/requirements-doc.txt sphinx: configuration: modules/account_statement/doc/conf.py diff --git a/modules/account_statement/doc/conf.py b/modules/account_statement/doc/conf.py index 540e9c3069..e16dc41c97 100644 --- a/modules/account_statement/doc/conf.py +++ b/modules/account_statement/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_statement/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_statement/doc/requirements-doc.txt b/modules/account_statement/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_statement/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_statement_aeb43/.readthedocs.yaml b/modules/account_statement_aeb43/.readthedocs.yaml index 84d4b59e0e..f0f00f891e 100644 --- a/modules/account_statement_aeb43/.readthedocs.yaml +++ b/modules/account_statement_aeb43/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_statement_aeb43/doc/requirements-doc.txt sphinx: configuration: modules/account_statement_aeb43/doc/conf.py diff --git a/modules/account_statement_aeb43/doc/conf.py b/modules/account_statement_aeb43/doc/conf.py index 540e9c3069..e50c7e8fcb 100644 --- a/modules/account_statement_aeb43/doc/conf.py +++ b/modules/account_statement_aeb43/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_statement_aeb43/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_statement_aeb43/doc/requirements-doc.txt b/modules/account_statement_aeb43/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_statement_aeb43/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_statement_coda/.readthedocs.yaml b/modules/account_statement_coda/.readthedocs.yaml index 54bb1a1e1a..78374d29fd 100644 --- a/modules/account_statement_coda/.readthedocs.yaml +++ b/modules/account_statement_coda/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_statement_coda/doc/requirements-doc.txt sphinx: configuration: modules/account_statement_coda/doc/conf.py diff --git a/modules/account_statement_coda/doc/conf.py b/modules/account_statement_coda/doc/conf.py index 540e9c3069..41bd66f29a 100644 --- a/modules/account_statement_coda/doc/conf.py +++ b/modules/account_statement_coda/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_statement_coda/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_statement_coda/doc/requirements-doc.txt b/modules/account_statement_coda/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_statement_coda/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_statement_mt940/.readthedocs.yaml b/modules/account_statement_mt940/.readthedocs.yaml index ef7dcf11b0..b8af1b6639 100644 --- a/modules/account_statement_mt940/.readthedocs.yaml +++ b/modules/account_statement_mt940/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_statement_mt940/doc/requirements-doc.txt sphinx: configuration: modules/account_statement_mt940/doc/conf.py diff --git a/modules/account_statement_mt940/doc/conf.py b/modules/account_statement_mt940/doc/conf.py index 540e9c3069..73772b63ea 100644 --- a/modules/account_statement_mt940/doc/conf.py +++ b/modules/account_statement_mt940/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_statement_mt940/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_statement_mt940/doc/requirements-doc.txt b/modules/account_statement_mt940/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_statement_mt940/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_statement_ofx/.readthedocs.yaml b/modules/account_statement_ofx/.readthedocs.yaml index be241ed901..c18c396098 100644 --- a/modules/account_statement_ofx/.readthedocs.yaml +++ b/modules/account_statement_ofx/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_statement_ofx/doc/requirements-doc.txt sphinx: configuration: modules/account_statement_ofx/doc/conf.py diff --git a/modules/account_statement_ofx/doc/conf.py b/modules/account_statement_ofx/doc/conf.py index 540e9c3069..0b2ca8bc82 100644 --- a/modules/account_statement_ofx/doc/conf.py +++ b/modules/account_statement_ofx/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_statement_ofx/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_statement_ofx/doc/requirements-doc.txt b/modules/account_statement_ofx/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_statement_ofx/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_statement_rule/.readthedocs.yaml b/modules/account_statement_rule/.readthedocs.yaml index 60ed5dd232..0ebe3e2b0f 100644 --- a/modules/account_statement_rule/.readthedocs.yaml +++ b/modules/account_statement_rule/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_statement_rule/doc/requirements-doc.txt sphinx: configuration: modules/account_statement_rule/doc/conf.py diff --git a/modules/account_statement_rule/doc/conf.py b/modules/account_statement_rule/doc/conf.py index 540e9c3069..a4f85fbd35 100644 --- a/modules/account_statement_rule/doc/conf.py +++ b/modules/account_statement_rule/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_statement_rule/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_statement_rule/doc/requirements-doc.txt b/modules/account_statement_rule/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_statement_rule/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_statement_sepa/.readthedocs.yaml b/modules/account_statement_sepa/.readthedocs.yaml index 3f25b7efac..6822ae37ac 100644 --- a/modules/account_statement_sepa/.readthedocs.yaml +++ b/modules/account_statement_sepa/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_statement_sepa/doc/requirements-doc.txt sphinx: configuration: modules/account_statement_sepa/doc/conf.py diff --git a/modules/account_statement_sepa/doc/conf.py b/modules/account_statement_sepa/doc/conf.py index 540e9c3069..5a1e9ccbef 100644 --- a/modules/account_statement_sepa/doc/conf.py +++ b/modules/account_statement_sepa/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_statement_sepa/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_statement_sepa/doc/requirements-doc.txt b/modules/account_statement_sepa/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_statement_sepa/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_stock_anglo_saxon/.readthedocs.yaml b/modules/account_stock_anglo_saxon/.readthedocs.yaml index 13372aff82..c9b224e220 100644 --- a/modules/account_stock_anglo_saxon/.readthedocs.yaml +++ b/modules/account_stock_anglo_saxon/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_stock_anglo_saxon/doc/requirements-doc.txt sphinx: configuration: modules/account_stock_anglo_saxon/doc/conf.py diff --git a/modules/account_stock_anglo_saxon/doc/conf.py b/modules/account_stock_anglo_saxon/doc/conf.py index 540e9c3069..2e577485bc 100644 --- a/modules/account_stock_anglo_saxon/doc/conf.py +++ b/modules/account_stock_anglo_saxon/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_stock_anglo_saxon/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_stock_anglo_saxon/doc/requirements-doc.txt b/modules/account_stock_anglo_saxon/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_stock_anglo_saxon/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_stock_continental/.readthedocs.yaml b/modules/account_stock_continental/.readthedocs.yaml index 5558eb5abe..28b48fbef3 100644 --- a/modules/account_stock_continental/.readthedocs.yaml +++ b/modules/account_stock_continental/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_stock_continental/doc/requirements-doc.txt sphinx: configuration: modules/account_stock_continental/doc/conf.py diff --git a/modules/account_stock_continental/doc/conf.py b/modules/account_stock_continental/doc/conf.py index 540e9c3069..b53e335c5a 100644 --- a/modules/account_stock_continental/doc/conf.py +++ b/modules/account_stock_continental/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_stock_continental/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_stock_continental/doc/requirements-doc.txt b/modules/account_stock_continental/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_stock_continental/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_stock_eu/.readthedocs.yaml b/modules/account_stock_eu/.readthedocs.yaml index d5511c147c..6f8890d403 100644 --- a/modules/account_stock_eu/.readthedocs.yaml +++ b/modules/account_stock_eu/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_stock_eu/doc/requirements-doc.txt sphinx: configuration: modules/account_stock_eu/doc/conf.py diff --git a/modules/account_stock_eu/doc/conf.py b/modules/account_stock_eu/doc/conf.py index 540e9c3069..9e4c323ba5 100644 --- a/modules/account_stock_eu/doc/conf.py +++ b/modules/account_stock_eu/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_stock_eu/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_stock_eu/doc/requirements-doc.txt b/modules/account_stock_eu/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_stock_eu/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_stock_landed_cost/.readthedocs.yaml b/modules/account_stock_landed_cost/.readthedocs.yaml index 1840978faa..97153137f6 100644 --- a/modules/account_stock_landed_cost/.readthedocs.yaml +++ b/modules/account_stock_landed_cost/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_stock_landed_cost/doc/requirements-doc.txt sphinx: configuration: modules/account_stock_landed_cost/doc/conf.py diff --git a/modules/account_stock_landed_cost/doc/conf.py b/modules/account_stock_landed_cost/doc/conf.py index 540e9c3069..135ae10cb2 100644 --- a/modules/account_stock_landed_cost/doc/conf.py +++ b/modules/account_stock_landed_cost/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_stock_landed_cost/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_stock_landed_cost/doc/requirements-doc.txt b/modules/account_stock_landed_cost/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_stock_landed_cost/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_stock_landed_cost_weight/.readthedocs.yaml b/modules/account_stock_landed_cost_weight/.readthedocs.yaml index d2a739043f..bca442d3a0 100644 --- a/modules/account_stock_landed_cost_weight/.readthedocs.yaml +++ b/modules/account_stock_landed_cost_weight/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_stock_landed_cost_weight/doc/requirements-doc.txt sphinx: configuration: modules/account_stock_landed_cost_weight/doc/conf.py diff --git a/modules/account_stock_landed_cost_weight/doc/conf.py b/modules/account_stock_landed_cost_weight/doc/conf.py index 540e9c3069..84faf6ccf7 100644 --- a/modules/account_stock_landed_cost_weight/doc/conf.py +++ b/modules/account_stock_landed_cost_weight/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_stock_landed_cost_weight/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_stock_landed_cost_weight/doc/requirements-doc.txt b/modules/account_stock_landed_cost_weight/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_stock_landed_cost_weight/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_stock_shipment_cost/.readthedocs.yaml b/modules/account_stock_shipment_cost/.readthedocs.yaml index c9855b4e42..dd942874d8 100644 --- a/modules/account_stock_shipment_cost/.readthedocs.yaml +++ b/modules/account_stock_shipment_cost/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_stock_shipment_cost/doc/requirements-doc.txt sphinx: configuration: modules/account_stock_shipment_cost/doc/conf.py diff --git a/modules/account_stock_shipment_cost/doc/conf.py b/modules/account_stock_shipment_cost/doc/conf.py index 540e9c3069..c9edeabbc7 100644 --- a/modules/account_stock_shipment_cost/doc/conf.py +++ b/modules/account_stock_shipment_cost/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_stock_shipment_cost/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_stock_shipment_cost/doc/requirements-doc.txt b/modules/account_stock_shipment_cost/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_stock_shipment_cost/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_stock_shipment_cost_weight/.readthedocs.yaml b/modules/account_stock_shipment_cost_weight/.readthedocs.yaml index d537253226..c13fde892d 100644 --- a/modules/account_stock_shipment_cost_weight/.readthedocs.yaml +++ b/modules/account_stock_shipment_cost_weight/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_stock_shipment_cost_weight/doc/requirements-doc.txt sphinx: configuration: modules/account_stock_shipment_cost_weight/doc/conf.py diff --git a/modules/account_stock_shipment_cost_weight/doc/conf.py b/modules/account_stock_shipment_cost_weight/doc/conf.py index 540e9c3069..b7dea0897d 100644 --- a/modules/account_stock_shipment_cost_weight/doc/conf.py +++ b/modules/account_stock_shipment_cost_weight/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_stock_shipment_cost_weight/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_stock_shipment_cost_weight/doc/requirements-doc.txt b/modules/account_stock_shipment_cost_weight/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_stock_shipment_cost_weight/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_tax_cash/.readthedocs.yaml b/modules/account_tax_cash/.readthedocs.yaml index c037b54afd..ae72c7e534 100644 --- a/modules/account_tax_cash/.readthedocs.yaml +++ b/modules/account_tax_cash/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_tax_cash/doc/requirements-doc.txt sphinx: configuration: modules/account_tax_cash/doc/conf.py diff --git a/modules/account_tax_cash/doc/conf.py b/modules/account_tax_cash/doc/conf.py index 540e9c3069..46cd8e8081 100644 --- a/modules/account_tax_cash/doc/conf.py +++ b/modules/account_tax_cash/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_tax_cash/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_tax_cash/doc/requirements-doc.txt b/modules/account_tax_cash/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_tax_cash/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_tax_non_deductible/.readthedocs.yaml b/modules/account_tax_non_deductible/.readthedocs.yaml index 9b618c2b06..6f4982a32d 100644 --- a/modules/account_tax_non_deductible/.readthedocs.yaml +++ b/modules/account_tax_non_deductible/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_tax_non_deductible/doc/requirements-doc.txt sphinx: configuration: modules/account_tax_non_deductible/doc/conf.py diff --git a/modules/account_tax_non_deductible/doc/conf.py b/modules/account_tax_non_deductible/doc/conf.py index 540e9c3069..2fcfab75c7 100644 --- a/modules/account_tax_non_deductible/doc/conf.py +++ b/modules/account_tax_non_deductible/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_tax_non_deductible/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_tax_non_deductible/doc/requirements-doc.txt b/modules/account_tax_non_deductible/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_tax_non_deductible/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/account_tax_rule_country/.readthedocs.yaml b/modules/account_tax_rule_country/.readthedocs.yaml index b283bdfd18..8ff4c3e3bc 100644 --- a/modules/account_tax_rule_country/.readthedocs.yaml +++ b/modules/account_tax_rule_country/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_account_tax_rule_country/doc/requirements-doc.txt sphinx: configuration: modules/account_tax_rule_country/doc/conf.py diff --git a/modules/account_tax_rule_country/doc/conf.py b/modules/account_tax_rule_country/doc/conf.py index 540e9c3069..497038c44d 100644 --- a/modules/account_tax_rule_country/doc/conf.py +++ b/modules/account_tax_rule_country/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/account_tax_rule_country/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/account_tax_rule_country/doc/requirements-doc.txt b/modules/account_tax_rule_country/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/account_tax_rule_country/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/analytic_account/.readthedocs.yaml b/modules/analytic_account/.readthedocs.yaml index 9b5b0be820..a14a3cc792 100644 --- a/modules/analytic_account/.readthedocs.yaml +++ b/modules/analytic_account/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_analytic_account/doc/requirements-doc.txt sphinx: configuration: modules/analytic_account/doc/conf.py diff --git a/modules/analytic_account/doc/conf.py b/modules/analytic_account/doc/conf.py index 540e9c3069..22d5dc25aa 100644 --- a/modules/analytic_account/doc/conf.py +++ b/modules/analytic_account/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/analytic_account/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/analytic_account/doc/requirements-doc.txt b/modules/analytic_account/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/analytic_account/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/analytic_budget/.readthedocs.yaml b/modules/analytic_budget/.readthedocs.yaml index 8cfe12dd3c..ca7c7e3bd5 100644 --- a/modules/analytic_budget/.readthedocs.yaml +++ b/modules/analytic_budget/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_analytic_budget/doc/requirements-doc.txt sphinx: configuration: modules/analytic_budget/doc/conf.py diff --git a/modules/analytic_budget/doc/conf.py b/modules/analytic_budget/doc/conf.py index 540e9c3069..1613001bfb 100644 --- a/modules/analytic_budget/doc/conf.py +++ b/modules/analytic_budget/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/analytic_budget/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/analytic_budget/doc/requirements-doc.txt b/modules/analytic_budget/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/analytic_budget/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/analytic_invoice/.readthedocs.yaml b/modules/analytic_invoice/.readthedocs.yaml index a5c42e012e..46a1d8b010 100644 --- a/modules/analytic_invoice/.readthedocs.yaml +++ b/modules/analytic_invoice/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_analytic_invoice/doc/requirements-doc.txt sphinx: configuration: modules/analytic_invoice/doc/conf.py diff --git a/modules/analytic_invoice/doc/conf.py b/modules/analytic_invoice/doc/conf.py index 540e9c3069..a3be8b8645 100644 --- a/modules/analytic_invoice/doc/conf.py +++ b/modules/analytic_invoice/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/analytic_invoice/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/analytic_invoice/doc/requirements-doc.txt b/modules/analytic_invoice/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/analytic_invoice/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/analytic_purchase/.readthedocs.yaml b/modules/analytic_purchase/.readthedocs.yaml index aac3a4060c..7b12d22d6c 100644 --- a/modules/analytic_purchase/.readthedocs.yaml +++ b/modules/analytic_purchase/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_analytic_purchase/doc/requirements-doc.txt sphinx: configuration: modules/analytic_purchase/doc/conf.py diff --git a/modules/analytic_purchase/doc/conf.py b/modules/analytic_purchase/doc/conf.py index 540e9c3069..93ee536ea0 100644 --- a/modules/analytic_purchase/doc/conf.py +++ b/modules/analytic_purchase/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/analytic_purchase/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/analytic_purchase/doc/requirements-doc.txt b/modules/analytic_purchase/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/analytic_purchase/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/analytic_sale/.readthedocs.yaml b/modules/analytic_sale/.readthedocs.yaml index 0c3405edcf..a0ecca8343 100644 --- a/modules/analytic_sale/.readthedocs.yaml +++ b/modules/analytic_sale/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_analytic_sale/doc/requirements-doc.txt sphinx: configuration: modules/analytic_sale/doc/conf.py diff --git a/modules/analytic_sale/doc/conf.py b/modules/analytic_sale/doc/conf.py index 540e9c3069..85429b5c16 100644 --- a/modules/analytic_sale/doc/conf.py +++ b/modules/analytic_sale/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/analytic_sale/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/analytic_sale/doc/requirements-doc.txt b/modules/analytic_sale/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/analytic_sale/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/attendance/.readthedocs.yaml b/modules/attendance/.readthedocs.yaml index 078bde9d3e..6be8667ac9 100644 --- a/modules/attendance/.readthedocs.yaml +++ b/modules/attendance/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_attendance/doc/requirements-doc.txt sphinx: configuration: modules/attendance/doc/conf.py diff --git a/modules/attendance/doc/conf.py b/modules/attendance/doc/conf.py index 540e9c3069..17d7c54af3 100644 --- a/modules/attendance/doc/conf.py +++ b/modules/attendance/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/attendance/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/attendance/doc/requirements-doc.txt b/modules/attendance/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/attendance/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/authentication_saml/.readthedocs.yaml b/modules/authentication_saml/.readthedocs.yaml index 78095f8104..e83295ef8f 100644 --- a/modules/authentication_saml/.readthedocs.yaml +++ b/modules/authentication_saml/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_authentication_saml/doc/requirements-doc.txt sphinx: configuration: modules/authentication_saml/doc/conf.py diff --git a/modules/authentication_saml/doc/conf.py b/modules/authentication_saml/doc/conf.py index 540e9c3069..98d0704e61 100644 --- a/modules/authentication_saml/doc/conf.py +++ b/modules/authentication_saml/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/authentication_saml/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/authentication_saml/doc/requirements-doc.txt b/modules/authentication_saml/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/authentication_saml/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/authentication_sms/.readthedocs.yaml b/modules/authentication_sms/.readthedocs.yaml index e768a464b5..fc4e131a98 100644 --- a/modules/authentication_sms/.readthedocs.yaml +++ b/modules/authentication_sms/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_authentication_sms/doc/requirements-doc.txt sphinx: configuration: modules/authentication_sms/doc/conf.py diff --git a/modules/authentication_sms/doc/conf.py b/modules/authentication_sms/doc/conf.py index 540e9c3069..49ca514dbc 100644 --- a/modules/authentication_sms/doc/conf.py +++ b/modules/authentication_sms/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/authentication_sms/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/authentication_sms/doc/requirements-doc.txt b/modules/authentication_sms/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/authentication_sms/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/bank/.readthedocs.yaml b/modules/bank/.readthedocs.yaml index aa9aadac04..839a8a4252 100644 --- a/modules/bank/.readthedocs.yaml +++ b/modules/bank/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_bank/doc/requirements-doc.txt sphinx: configuration: modules/bank/doc/conf.py diff --git a/modules/bank/doc/conf.py b/modules/bank/doc/conf.py index 540e9c3069..5e82109d93 100644 --- a/modules/bank/doc/conf.py +++ b/modules/bank/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/bank/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/bank/doc/requirements-doc.txt b/modules/bank/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/bank/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/carrier/.readthedocs.yaml b/modules/carrier/.readthedocs.yaml index 78aef51f62..ca9588612f 100644 --- a/modules/carrier/.readthedocs.yaml +++ b/modules/carrier/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_carrier/doc/requirements-doc.txt sphinx: configuration: modules/carrier/doc/conf.py diff --git a/modules/carrier/doc/conf.py b/modules/carrier/doc/conf.py index 540e9c3069..cd2c7fa638 100644 --- a/modules/carrier/doc/conf.py +++ b/modules/carrier/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/carrier/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/carrier/doc/requirements-doc.txt b/modules/carrier/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/carrier/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/carrier_carriage/.readthedocs.yaml b/modules/carrier_carriage/.readthedocs.yaml index 3ef1fd6907..dc675d20b0 100644 --- a/modules/carrier_carriage/.readthedocs.yaml +++ b/modules/carrier_carriage/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_carrier_carriage/doc/requirements-doc.txt sphinx: configuration: modules/carrier_carriage/doc/conf.py diff --git a/modules/carrier_carriage/doc/conf.py b/modules/carrier_carriage/doc/conf.py index 540e9c3069..3f2aacf7e2 100644 --- a/modules/carrier_carriage/doc/conf.py +++ b/modules/carrier_carriage/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/carrier_carriage/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/carrier_carriage/doc/requirements-doc.txt b/modules/carrier_carriage/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/carrier_carriage/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/carrier_percentage/.readthedocs.yaml b/modules/carrier_percentage/.readthedocs.yaml index 64dee78f69..a53133ef02 100644 --- a/modules/carrier_percentage/.readthedocs.yaml +++ b/modules/carrier_percentage/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_carrier_percentage/doc/requirements-doc.txt sphinx: configuration: modules/carrier_percentage/doc/conf.py diff --git a/modules/carrier_percentage/doc/conf.py b/modules/carrier_percentage/doc/conf.py index 540e9c3069..1cf9521f90 100644 --- a/modules/carrier_percentage/doc/conf.py +++ b/modules/carrier_percentage/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/carrier_percentage/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/carrier_percentage/doc/requirements-doc.txt b/modules/carrier_percentage/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/carrier_percentage/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/carrier_subdivision/.readthedocs.yaml b/modules/carrier_subdivision/.readthedocs.yaml index 580fae8ca8..64fa4c4ce3 100644 --- a/modules/carrier_subdivision/.readthedocs.yaml +++ b/modules/carrier_subdivision/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_carrier_subdivision/doc/requirements-doc.txt sphinx: configuration: modules/carrier_subdivision/doc/conf.py diff --git a/modules/carrier_subdivision/doc/conf.py b/modules/carrier_subdivision/doc/conf.py index 540e9c3069..f82055598d 100644 --- a/modules/carrier_subdivision/doc/conf.py +++ b/modules/carrier_subdivision/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/carrier_subdivision/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/carrier_subdivision/doc/requirements-doc.txt b/modules/carrier_subdivision/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/carrier_subdivision/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/carrier_weight/.readthedocs.yaml b/modules/carrier_weight/.readthedocs.yaml index a8eeb1b1a7..882546fc94 100644 --- a/modules/carrier_weight/.readthedocs.yaml +++ b/modules/carrier_weight/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_carrier_weight/doc/requirements-doc.txt sphinx: configuration: modules/carrier_weight/doc/conf.py diff --git a/modules/carrier_weight/doc/conf.py b/modules/carrier_weight/doc/conf.py index 540e9c3069..2b28af91d6 100644 --- a/modules/carrier_weight/doc/conf.py +++ b/modules/carrier_weight/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/carrier_weight/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/carrier_weight/doc/requirements-doc.txt b/modules/carrier_weight/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/carrier_weight/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/commission/.readthedocs.yaml b/modules/commission/.readthedocs.yaml index b923ec3f07..2cc5568f81 100644 --- a/modules/commission/.readthedocs.yaml +++ b/modules/commission/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_commission/doc/requirements-doc.txt sphinx: configuration: modules/commission/doc/conf.py diff --git a/modules/commission/doc/conf.py b/modules/commission/doc/conf.py index 540e9c3069..b51e519a37 100644 --- a/modules/commission/doc/conf.py +++ b/modules/commission/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/commission/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/commission/doc/requirements-doc.txt b/modules/commission/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/commission/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/commission_waiting/.readthedocs.yaml b/modules/commission_waiting/.readthedocs.yaml index 70f99167b1..4bc9a82070 100644 --- a/modules/commission_waiting/.readthedocs.yaml +++ b/modules/commission_waiting/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_commission_waiting/doc/requirements-doc.txt sphinx: configuration: modules/commission_waiting/doc/conf.py diff --git a/modules/commission_waiting/doc/conf.py b/modules/commission_waiting/doc/conf.py index 540e9c3069..9f39d4c7bb 100644 --- a/modules/commission_waiting/doc/conf.py +++ b/modules/commission_waiting/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/commission_waiting/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/commission_waiting/doc/requirements-doc.txt b/modules/commission_waiting/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/commission_waiting/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/company/.readthedocs.yaml b/modules/company/.readthedocs.yaml index eb55a0452a..78a24f4ea2 100644 --- a/modules/company/.readthedocs.yaml +++ b/modules/company/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_company/doc/requirements-doc.txt sphinx: configuration: modules/company/doc/conf.py diff --git a/modules/company/doc/conf.py b/modules/company/doc/conf.py index 540e9c3069..c02c03133a 100644 --- a/modules/company/doc/conf.py +++ b/modules/company/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/company/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/company/doc/requirements-doc.txt b/modules/company/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/company/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/company_work_time/.readthedocs.yaml b/modules/company_work_time/.readthedocs.yaml index 92c38d0969..8bcd4f11c4 100644 --- a/modules/company_work_time/.readthedocs.yaml +++ b/modules/company_work_time/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_company_work_time/doc/requirements-doc.txt sphinx: configuration: modules/company_work_time/doc/conf.py diff --git a/modules/company_work_time/doc/conf.py b/modules/company_work_time/doc/conf.py index 540e9c3069..9e431b2cca 100644 --- a/modules/company_work_time/doc/conf.py +++ b/modules/company_work_time/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/company_work_time/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/company_work_time/doc/requirements-doc.txt b/modules/company_work_time/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/company_work_time/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/country/.readthedocs.yaml b/modules/country/.readthedocs.yaml index 4f9eba0dde..b2756c735d 100644 --- a/modules/country/.readthedocs.yaml +++ b/modules/country/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_country/doc/requirements-doc.txt sphinx: configuration: modules/country/doc/conf.py diff --git a/modules/country/doc/conf.py b/modules/country/doc/conf.py index 540e9c3069..38f4285b76 100644 --- a/modules/country/doc/conf.py +++ b/modules/country/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/country/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/country/doc/requirements-doc.txt b/modules/country/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/country/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/currency/.readthedocs.yaml b/modules/currency/.readthedocs.yaml index ff36056851..6181e86504 100644 --- a/modules/currency/.readthedocs.yaml +++ b/modules/currency/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_currency/doc/requirements-doc.txt sphinx: configuration: modules/currency/doc/conf.py diff --git a/modules/currency/doc/conf.py b/modules/currency/doc/conf.py index 540e9c3069..58882becf8 100644 --- a/modules/currency/doc/conf.py +++ b/modules/currency/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/currency/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/currency/doc/requirements-doc.txt b/modules/currency/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/currency/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/currency_ro/.readthedocs.yaml b/modules/currency_ro/.readthedocs.yaml index 780dc925e9..b54a109a11 100644 --- a/modules/currency_ro/.readthedocs.yaml +++ b/modules/currency_ro/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_currency_ro/doc/requirements-doc.txt sphinx: configuration: modules/currency_ro/doc/conf.py diff --git a/modules/currency_ro/doc/conf.py b/modules/currency_ro/doc/conf.py index 540e9c3069..2f930f14b1 100644 --- a/modules/currency_ro/doc/conf.py +++ b/modules/currency_ro/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/currency_ro/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/currency_ro/doc/requirements-doc.txt b/modules/currency_ro/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/currency_ro/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/currency_rs/.readthedocs.yaml b/modules/currency_rs/.readthedocs.yaml index 274d39c6f6..9acc6b2dea 100644 --- a/modules/currency_rs/.readthedocs.yaml +++ b/modules/currency_rs/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_currency_rs/doc/requirements-doc.txt sphinx: configuration: modules/currency_rs/doc/conf.py diff --git a/modules/currency_rs/doc/conf.py b/modules/currency_rs/doc/conf.py index 540e9c3069..e28183be2c 100644 --- a/modules/currency_rs/doc/conf.py +++ b/modules/currency_rs/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/currency_rs/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/currency_rs/doc/requirements-doc.txt b/modules/currency_rs/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/currency_rs/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/customs/.readthedocs.yaml b/modules/customs/.readthedocs.yaml index 739e483d6e..ec2a66cee7 100644 --- a/modules/customs/.readthedocs.yaml +++ b/modules/customs/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_customs/doc/requirements-doc.txt sphinx: configuration: modules/customs/doc/conf.py diff --git a/modules/customs/doc/conf.py b/modules/customs/doc/conf.py index 540e9c3069..26b55feb4e 100644 --- a/modules/customs/doc/conf.py +++ b/modules/customs/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/customs/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/customs/doc/requirements-doc.txt b/modules/customs/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/customs/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/dashboard/.readthedocs.yaml b/modules/dashboard/.readthedocs.yaml index 6945e63118..3fa105774a 100644 --- a/modules/dashboard/.readthedocs.yaml +++ b/modules/dashboard/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_dashboard/doc/requirements-doc.txt sphinx: configuration: modules/dashboard/doc/conf.py diff --git a/modules/dashboard/doc/conf.py b/modules/dashboard/doc/conf.py index 540e9c3069..f8aa8b4ea6 100644 --- a/modules/dashboard/doc/conf.py +++ b/modules/dashboard/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/dashboard/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/dashboard/doc/requirements-doc.txt b/modules/dashboard/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/dashboard/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/edocument_uncefact/.readthedocs.yaml b/modules/edocument_uncefact/.readthedocs.yaml index 21ed715aba..019727caa2 100644 --- a/modules/edocument_uncefact/.readthedocs.yaml +++ b/modules/edocument_uncefact/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_edocument_uncefact/doc/requirements-doc.txt sphinx: configuration: modules/edocument_uncefact/doc/conf.py diff --git a/modules/edocument_uncefact/doc/conf.py b/modules/edocument_uncefact/doc/conf.py index 540e9c3069..51e661e55d 100644 --- a/modules/edocument_uncefact/doc/conf.py +++ b/modules/edocument_uncefact/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/edocument_uncefact/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/edocument_uncefact/doc/requirements-doc.txt b/modules/edocument_uncefact/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/edocument_uncefact/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/edocument_unece/.readthedocs.yaml b/modules/edocument_unece/.readthedocs.yaml index 5ba19371f3..b5ab3420a5 100644 --- a/modules/edocument_unece/.readthedocs.yaml +++ b/modules/edocument_unece/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_edocument_unece/doc/requirements-doc.txt sphinx: configuration: modules/edocument_unece/doc/conf.py diff --git a/modules/edocument_unece/doc/conf.py b/modules/edocument_unece/doc/conf.py index 540e9c3069..fd049b4e4b 100644 --- a/modules/edocument_unece/doc/conf.py +++ b/modules/edocument_unece/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/edocument_unece/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/edocument_unece/doc/requirements-doc.txt b/modules/edocument_unece/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/edocument_unece/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/google_maps/.readthedocs.yaml b/modules/google_maps/.readthedocs.yaml index 503624ffe1..3eaf966fbb 100644 --- a/modules/google_maps/.readthedocs.yaml +++ b/modules/google_maps/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_google_maps/doc/requirements-doc.txt sphinx: configuration: modules/google_maps/doc/conf.py diff --git a/modules/google_maps/doc/conf.py b/modules/google_maps/doc/conf.py index 540e9c3069..fbb76f24de 100644 --- a/modules/google_maps/doc/conf.py +++ b/modules/google_maps/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/google_maps/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/google_maps/doc/requirements-doc.txt b/modules/google_maps/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/google_maps/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/incoterm/.readthedocs.yaml b/modules/incoterm/.readthedocs.yaml index 196c716a7f..8a7b1635d4 100644 --- a/modules/incoterm/.readthedocs.yaml +++ b/modules/incoterm/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_incoterm/doc/requirements-doc.txt sphinx: configuration: modules/incoterm/doc/conf.py diff --git a/modules/incoterm/doc/conf.py b/modules/incoterm/doc/conf.py index 540e9c3069..fcaeab1ff4 100644 --- a/modules/incoterm/doc/conf.py +++ b/modules/incoterm/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/incoterm/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/incoterm/doc/requirements-doc.txt b/modules/incoterm/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/incoterm/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/ldap_authentication/.readthedocs.yaml b/modules/ldap_authentication/.readthedocs.yaml index 86320c8332..172e7c4f88 100644 --- a/modules/ldap_authentication/.readthedocs.yaml +++ b/modules/ldap_authentication/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_ldap_authentication/doc/requirements-doc.txt sphinx: configuration: modules/ldap_authentication/doc/conf.py diff --git a/modules/ldap_authentication/doc/conf.py b/modules/ldap_authentication/doc/conf.py index 540e9c3069..7e284cfbc5 100644 --- a/modules/ldap_authentication/doc/conf.py +++ b/modules/ldap_authentication/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/ldap_authentication/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/ldap_authentication/doc/requirements-doc.txt b/modules/ldap_authentication/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/ldap_authentication/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/marketing/.readthedocs.yaml b/modules/marketing/.readthedocs.yaml index 0c3979d05e..305bfb7b21 100644 --- a/modules/marketing/.readthedocs.yaml +++ b/modules/marketing/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_marketing/doc/requirements-doc.txt sphinx: configuration: modules/marketing/doc/conf.py diff --git a/modules/marketing/doc/conf.py b/modules/marketing/doc/conf.py index 540e9c3069..cf0d8783f7 100644 --- a/modules/marketing/doc/conf.py +++ b/modules/marketing/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/marketing/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/marketing/doc/requirements-doc.txt b/modules/marketing/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/marketing/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/marketing_automation/.readthedocs.yaml b/modules/marketing_automation/.readthedocs.yaml index a37823af9c..4122de6199 100644 --- a/modules/marketing_automation/.readthedocs.yaml +++ b/modules/marketing_automation/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_marketing_automation/doc/requirements-doc.txt sphinx: configuration: modules/marketing_automation/doc/conf.py diff --git a/modules/marketing_automation/doc/conf.py b/modules/marketing_automation/doc/conf.py index 540e9c3069..e807249bfe 100644 --- a/modules/marketing_automation/doc/conf.py +++ b/modules/marketing_automation/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/marketing_automation/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/marketing_automation/doc/requirements-doc.txt b/modules/marketing_automation/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/marketing_automation/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/marketing_campaign/.readthedocs.yaml b/modules/marketing_campaign/.readthedocs.yaml index 3e29513d9a..f04e543381 100644 --- a/modules/marketing_campaign/.readthedocs.yaml +++ b/modules/marketing_campaign/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_marketing_campaign/doc/requirements-doc.txt sphinx: configuration: modules/marketing_campaign/doc/conf.py diff --git a/modules/marketing_campaign/doc/conf.py b/modules/marketing_campaign/doc/conf.py index 540e9c3069..8828b4f4be 100644 --- a/modules/marketing_campaign/doc/conf.py +++ b/modules/marketing_campaign/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/marketing_campaign/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/marketing_campaign/doc/requirements-doc.txt b/modules/marketing_campaign/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/marketing_campaign/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/marketing_email/.readthedocs.yaml b/modules/marketing_email/.readthedocs.yaml index 4b05248acd..e6a397239d 100644 --- a/modules/marketing_email/.readthedocs.yaml +++ b/modules/marketing_email/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_marketing_email/doc/requirements-doc.txt sphinx: configuration: modules/marketing_email/doc/conf.py diff --git a/modules/marketing_email/doc/conf.py b/modules/marketing_email/doc/conf.py index 540e9c3069..725be107de 100644 --- a/modules/marketing_email/doc/conf.py +++ b/modules/marketing_email/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/marketing_email/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/marketing_email/doc/requirements-doc.txt b/modules/marketing_email/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/marketing_email/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/notification_email/.readthedocs.yaml b/modules/notification_email/.readthedocs.yaml index 11ea6541cf..b171b4d52f 100644 --- a/modules/notification_email/.readthedocs.yaml +++ b/modules/notification_email/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_notification_email/doc/requirements-doc.txt sphinx: configuration: modules/notification_email/doc/conf.py diff --git a/modules/notification_email/doc/conf.py b/modules/notification_email/doc/conf.py index 540e9c3069..9234df631d 100644 --- a/modules/notification_email/doc/conf.py +++ b/modules/notification_email/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/notification_email/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/notification_email/doc/requirements-doc.txt b/modules/notification_email/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/notification_email/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/party/.readthedocs.yaml b/modules/party/.readthedocs.yaml index 1fa219d6c2..29322d0847 100644 --- a/modules/party/.readthedocs.yaml +++ b/modules/party/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_party/doc/requirements-doc.txt sphinx: configuration: modules/party/doc/conf.py diff --git a/modules/party/doc/conf.py b/modules/party/doc/conf.py index 540e9c3069..800b3876da 100644 --- a/modules/party/doc/conf.py +++ b/modules/party/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/party/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/party/doc/requirements-doc.txt b/modules/party/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/party/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/party_avatar/.readthedocs.yaml b/modules/party_avatar/.readthedocs.yaml index 1eb84d8d47..3de5b31fab 100644 --- a/modules/party_avatar/.readthedocs.yaml +++ b/modules/party_avatar/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_party_avatar/doc/requirements-doc.txt sphinx: configuration: modules/party_avatar/doc/conf.py diff --git a/modules/party_avatar/doc/conf.py b/modules/party_avatar/doc/conf.py index 540e9c3069..125cdd70e6 100644 --- a/modules/party_avatar/doc/conf.py +++ b/modules/party_avatar/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/party_avatar/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/party_avatar/doc/requirements-doc.txt b/modules/party_avatar/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/party_avatar/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/party_relationship/.readthedocs.yaml b/modules/party_relationship/.readthedocs.yaml index f6a0a0728c..577ec31704 100644 --- a/modules/party_relationship/.readthedocs.yaml +++ b/modules/party_relationship/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_party_relationship/doc/requirements-doc.txt sphinx: configuration: modules/party_relationship/doc/conf.py diff --git a/modules/party_relationship/doc/conf.py b/modules/party_relationship/doc/conf.py index 540e9c3069..84eae0faea 100644 --- a/modules/party_relationship/doc/conf.py +++ b/modules/party_relationship/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/party_relationship/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/party_relationship/doc/requirements-doc.txt b/modules/party_relationship/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/party_relationship/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/party_siret/.readthedocs.yaml b/modules/party_siret/.readthedocs.yaml index 9a22706e2c..c4f6964090 100644 --- a/modules/party_siret/.readthedocs.yaml +++ b/modules/party_siret/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_party_siret/doc/requirements-doc.txt sphinx: configuration: modules/party_siret/doc/conf.py diff --git a/modules/party_siret/doc/conf.py b/modules/party_siret/doc/conf.py index 540e9c3069..90807b60c2 100644 --- a/modules/party_siret/doc/conf.py +++ b/modules/party_siret/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/party_siret/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/party_siret/doc/requirements-doc.txt b/modules/party_siret/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/party_siret/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product/.readthedocs.yaml b/modules/product/.readthedocs.yaml index ff05102103..abb0467458 100644 --- a/modules/product/.readthedocs.yaml +++ b/modules/product/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product/doc/requirements-doc.txt sphinx: configuration: modules/product/doc/conf.py diff --git a/modules/product/doc/conf.py b/modules/product/doc/conf.py index 540e9c3069..30fbc7ec5a 100644 --- a/modules/product/doc/conf.py +++ b/modules/product/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product/doc/requirements-doc.txt b/modules/product/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_attribute/.readthedocs.yaml b/modules/product_attribute/.readthedocs.yaml index 7560d6649e..8bc3508792 100644 --- a/modules/product_attribute/.readthedocs.yaml +++ b/modules/product_attribute/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_attribute/doc/requirements-doc.txt sphinx: configuration: modules/product_attribute/doc/conf.py diff --git a/modules/product_attribute/doc/conf.py b/modules/product_attribute/doc/conf.py index 540e9c3069..14db516fe8 100644 --- a/modules/product_attribute/doc/conf.py +++ b/modules/product_attribute/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_attribute/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_attribute/doc/requirements-doc.txt b/modules/product_attribute/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_attribute/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_classification/.readthedocs.yaml b/modules/product_classification/.readthedocs.yaml index 69435a581a..c3fd9887aa 100644 --- a/modules/product_classification/.readthedocs.yaml +++ b/modules/product_classification/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_classification/doc/requirements-doc.txt sphinx: configuration: modules/product_classification/doc/conf.py diff --git a/modules/product_classification/doc/conf.py b/modules/product_classification/doc/conf.py index 540e9c3069..0476637b67 100644 --- a/modules/product_classification/doc/conf.py +++ b/modules/product_classification/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_classification/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_classification/doc/requirements-doc.txt b/modules/product_classification/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_classification/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_classification_taxonomic/.readthedocs.yaml b/modules/product_classification_taxonomic/.readthedocs.yaml index f1e64f927f..793f4e1c8d 100644 --- a/modules/product_classification_taxonomic/.readthedocs.yaml +++ b/modules/product_classification_taxonomic/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_classification_taxonomic/doc/requirements-doc.txt sphinx: configuration: modules/product_classification_taxonomic/doc/conf.py diff --git a/modules/product_classification_taxonomic/doc/conf.py b/modules/product_classification_taxonomic/doc/conf.py index 540e9c3069..ec87aae636 100644 --- a/modules/product_classification_taxonomic/doc/conf.py +++ b/modules/product_classification_taxonomic/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_classification_taxonomic/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_classification_taxonomic/doc/requirements-doc.txt b/modules/product_classification_taxonomic/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_classification_taxonomic/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_cost_fifo/.readthedocs.yaml b/modules/product_cost_fifo/.readthedocs.yaml index 8d5da0ed31..422bb64d68 100644 --- a/modules/product_cost_fifo/.readthedocs.yaml +++ b/modules/product_cost_fifo/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_cost_fifo/doc/requirements-doc.txt sphinx: configuration: modules/product_cost_fifo/doc/conf.py diff --git a/modules/product_cost_fifo/doc/conf.py b/modules/product_cost_fifo/doc/conf.py index 540e9c3069..5122c0b63b 100644 --- a/modules/product_cost_fifo/doc/conf.py +++ b/modules/product_cost_fifo/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_cost_fifo/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_cost_fifo/doc/requirements-doc.txt b/modules/product_cost_fifo/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_cost_fifo/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_cost_history/.readthedocs.yaml b/modules/product_cost_history/.readthedocs.yaml index ee4fd7e556..5ed46b3e11 100644 --- a/modules/product_cost_history/.readthedocs.yaml +++ b/modules/product_cost_history/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_cost_history/doc/requirements-doc.txt sphinx: configuration: modules/product_cost_history/doc/conf.py diff --git a/modules/product_cost_history/doc/conf.py b/modules/product_cost_history/doc/conf.py index 540e9c3069..e2213f0426 100644 --- a/modules/product_cost_history/doc/conf.py +++ b/modules/product_cost_history/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_cost_history/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_cost_history/doc/requirements-doc.txt b/modules/product_cost_history/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_cost_history/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_cost_warehouse/.readthedocs.yaml b/modules/product_cost_warehouse/.readthedocs.yaml index 594c89651c..6312c08bc7 100644 --- a/modules/product_cost_warehouse/.readthedocs.yaml +++ b/modules/product_cost_warehouse/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_cost_warehouse/doc/requirements-doc.txt sphinx: configuration: modules/product_cost_warehouse/doc/conf.py diff --git a/modules/product_cost_warehouse/doc/conf.py b/modules/product_cost_warehouse/doc/conf.py index 540e9c3069..4f3bb5ef52 100644 --- a/modules/product_cost_warehouse/doc/conf.py +++ b/modules/product_cost_warehouse/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_cost_warehouse/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_cost_warehouse/doc/requirements-doc.txt b/modules/product_cost_warehouse/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_cost_warehouse/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_image/.readthedocs.yaml b/modules/product_image/.readthedocs.yaml index 8086f01adc..9ee51186f4 100644 --- a/modules/product_image/.readthedocs.yaml +++ b/modules/product_image/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_image/doc/requirements-doc.txt sphinx: configuration: modules/product_image/doc/conf.py diff --git a/modules/product_image/doc/conf.py b/modules/product_image/doc/conf.py index 540e9c3069..b3dfd44d04 100644 --- a/modules/product_image/doc/conf.py +++ b/modules/product_image/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_image/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_image/doc/requirements-doc.txt b/modules/product_image/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_image/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_image_attribute/.readthedocs.yaml b/modules/product_image_attribute/.readthedocs.yaml index 9ff51852e0..a636d67a46 100644 --- a/modules/product_image_attribute/.readthedocs.yaml +++ b/modules/product_image_attribute/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_image_attribute/doc/requirements-doc.txt sphinx: configuration: modules/product_image_attribute/doc/conf.py diff --git a/modules/product_image_attribute/doc/conf.py b/modules/product_image_attribute/doc/conf.py index 540e9c3069..9cff6e8672 100644 --- a/modules/product_image_attribute/doc/conf.py +++ b/modules/product_image_attribute/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_image_attribute/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_image_attribute/doc/requirements-doc.txt b/modules/product_image_attribute/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_image_attribute/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_kit/.readthedocs.yaml b/modules/product_kit/.readthedocs.yaml index fd567f1ffd..07a3c82100 100644 --- a/modules/product_kit/.readthedocs.yaml +++ b/modules/product_kit/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_kit/doc/requirements-doc.txt sphinx: configuration: modules/product_kit/doc/conf.py diff --git a/modules/product_kit/doc/conf.py b/modules/product_kit/doc/conf.py index 540e9c3069..a3778e20d8 100644 --- a/modules/product_kit/doc/conf.py +++ b/modules/product_kit/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_kit/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_kit/doc/requirements-doc.txt b/modules/product_kit/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_kit/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_measurements/.readthedocs.yaml b/modules/product_measurements/.readthedocs.yaml index f5c81a6f5d..1983eb592d 100644 --- a/modules/product_measurements/.readthedocs.yaml +++ b/modules/product_measurements/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_measurements/doc/requirements-doc.txt sphinx: configuration: modules/product_measurements/doc/conf.py diff --git a/modules/product_measurements/doc/conf.py b/modules/product_measurements/doc/conf.py index 540e9c3069..09094766ec 100644 --- a/modules/product_measurements/doc/conf.py +++ b/modules/product_measurements/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_measurements/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_measurements/doc/requirements-doc.txt b/modules/product_measurements/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_measurements/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_price_list/.readthedocs.yaml b/modules/product_price_list/.readthedocs.yaml index b867b02335..bc07bdca84 100644 --- a/modules/product_price_list/.readthedocs.yaml +++ b/modules/product_price_list/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_price_list/doc/requirements-doc.txt sphinx: configuration: modules/product_price_list/doc/conf.py diff --git a/modules/product_price_list/doc/conf.py b/modules/product_price_list/doc/conf.py index 540e9c3069..0608ff5e8e 100644 --- a/modules/product_price_list/doc/conf.py +++ b/modules/product_price_list/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_price_list/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_price_list/doc/requirements-doc.txt b/modules/product_price_list/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_price_list/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_price_list_cache/.readthedocs.yaml b/modules/product_price_list_cache/.readthedocs.yaml index 75b48778c3..e2d0dc8185 100644 --- a/modules/product_price_list_cache/.readthedocs.yaml +++ b/modules/product_price_list_cache/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_price_list_cache/doc/requirements-doc.txt sphinx: configuration: modules/product_price_list_cache/doc/conf.py diff --git a/modules/product_price_list_cache/doc/conf.py b/modules/product_price_list_cache/doc/conf.py index 540e9c3069..ef0dec4fdd 100644 --- a/modules/product_price_list_cache/doc/conf.py +++ b/modules/product_price_list_cache/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_price_list_cache/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_price_list_cache/doc/requirements-doc.txt b/modules/product_price_list_cache/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_price_list_cache/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_price_list_dates/.readthedocs.yaml b/modules/product_price_list_dates/.readthedocs.yaml index 79d192bd94..f26e2a83f5 100644 --- a/modules/product_price_list_dates/.readthedocs.yaml +++ b/modules/product_price_list_dates/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_price_list_dates/doc/requirements-doc.txt sphinx: configuration: modules/product_price_list_dates/doc/conf.py diff --git a/modules/product_price_list_dates/doc/conf.py b/modules/product_price_list_dates/doc/conf.py index 540e9c3069..d48afa81a6 100644 --- a/modules/product_price_list_dates/doc/conf.py +++ b/modules/product_price_list_dates/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_price_list_dates/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_price_list_dates/doc/requirements-doc.txt b/modules/product_price_list_dates/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_price_list_dates/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/product_price_list_parent/.readthedocs.yaml b/modules/product_price_list_parent/.readthedocs.yaml index 3fc9aee38d..9b07674b68 100644 --- a/modules/product_price_list_parent/.readthedocs.yaml +++ b/modules/product_price_list_parent/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_product_price_list_parent/doc/requirements-doc.txt sphinx: configuration: modules/product_price_list_parent/doc/conf.py diff --git a/modules/product_price_list_parent/doc/conf.py b/modules/product_price_list_parent/doc/conf.py index 540e9c3069..115b1e7405 100644 --- a/modules/product_price_list_parent/doc/conf.py +++ b/modules/product_price_list_parent/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/product_price_list_parent/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/product_price_list_parent/doc/requirements-doc.txt b/modules/product_price_list_parent/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/product_price_list_parent/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/production/.readthedocs.yaml b/modules/production/.readthedocs.yaml index dd3358df89..1bc7e41d0d 100644 --- a/modules/production/.readthedocs.yaml +++ b/modules/production/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_production/doc/requirements-doc.txt sphinx: configuration: modules/production/doc/conf.py diff --git a/modules/production/doc/conf.py b/modules/production/doc/conf.py index 540e9c3069..c82e793ecd 100644 --- a/modules/production/doc/conf.py +++ b/modules/production/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/production/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/production/doc/requirements-doc.txt b/modules/production/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/production/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/production_outsourcing/.readthedocs.yaml b/modules/production_outsourcing/.readthedocs.yaml index 6b9d1fde64..f63dc46705 100644 --- a/modules/production_outsourcing/.readthedocs.yaml +++ b/modules/production_outsourcing/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_production_outsourcing/doc/requirements-doc.txt sphinx: configuration: modules/production_outsourcing/doc/conf.py diff --git a/modules/production_outsourcing/doc/conf.py b/modules/production_outsourcing/doc/conf.py index 540e9c3069..0ad52a330b 100644 --- a/modules/production_outsourcing/doc/conf.py +++ b/modules/production_outsourcing/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/production_outsourcing/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/production_outsourcing/doc/requirements-doc.txt b/modules/production_outsourcing/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/production_outsourcing/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/production_routing/.readthedocs.yaml b/modules/production_routing/.readthedocs.yaml index 25e4d47e84..269efc8460 100644 --- a/modules/production_routing/.readthedocs.yaml +++ b/modules/production_routing/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_production_routing/doc/requirements-doc.txt sphinx: configuration: modules/production_routing/doc/conf.py diff --git a/modules/production_routing/doc/conf.py b/modules/production_routing/doc/conf.py index 540e9c3069..98d03a61a7 100644 --- a/modules/production_routing/doc/conf.py +++ b/modules/production_routing/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/production_routing/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/production_routing/doc/requirements-doc.txt b/modules/production_routing/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/production_routing/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/production_split/.readthedocs.yaml b/modules/production_split/.readthedocs.yaml index 51762073b1..bc8bcf54a3 100644 --- a/modules/production_split/.readthedocs.yaml +++ b/modules/production_split/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_production_split/doc/requirements-doc.txt sphinx: configuration: modules/production_split/doc/conf.py diff --git a/modules/production_split/doc/conf.py b/modules/production_split/doc/conf.py index 540e9c3069..0d15f5205d 100644 --- a/modules/production_split/doc/conf.py +++ b/modules/production_split/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/production_split/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/production_split/doc/requirements-doc.txt b/modules/production_split/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/production_split/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/production_work/.readthedocs.yaml b/modules/production_work/.readthedocs.yaml index 371fdae1e6..ea068d7af6 100644 --- a/modules/production_work/.readthedocs.yaml +++ b/modules/production_work/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_production_work/doc/requirements-doc.txt sphinx: configuration: modules/production_work/doc/conf.py diff --git a/modules/production_work/doc/conf.py b/modules/production_work/doc/conf.py index 540e9c3069..9404cd8eac 100644 --- a/modules/production_work/doc/conf.py +++ b/modules/production_work/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/production_work/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/production_work/doc/requirements-doc.txt b/modules/production_work/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/production_work/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/production_work_timesheet/.readthedocs.yaml b/modules/production_work_timesheet/.readthedocs.yaml index a0486ca2ac..ff1a6b6678 100644 --- a/modules/production_work_timesheet/.readthedocs.yaml +++ b/modules/production_work_timesheet/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_production_work_timesheet/doc/requirements-doc.txt sphinx: configuration: modules/production_work_timesheet/doc/conf.py diff --git a/modules/production_work_timesheet/doc/conf.py b/modules/production_work_timesheet/doc/conf.py index 540e9c3069..25009b3662 100644 --- a/modules/production_work_timesheet/doc/conf.py +++ b/modules/production_work_timesheet/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/production_work_timesheet/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/production_work_timesheet/doc/requirements-doc.txt b/modules/production_work_timesheet/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/production_work_timesheet/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/project/.readthedocs.yaml b/modules/project/.readthedocs.yaml index 7af3eed86a..29456348d4 100644 --- a/modules/project/.readthedocs.yaml +++ b/modules/project/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_project/doc/requirements-doc.txt sphinx: configuration: modules/project/doc/conf.py diff --git a/modules/project/doc/conf.py b/modules/project/doc/conf.py index 540e9c3069..79649eef2c 100644 --- a/modules/project/doc/conf.py +++ b/modules/project/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/project/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/project/doc/requirements-doc.txt b/modules/project/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/project/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/project_invoice/.readthedocs.yaml b/modules/project_invoice/.readthedocs.yaml index 842404e895..520f60ce57 100644 --- a/modules/project_invoice/.readthedocs.yaml +++ b/modules/project_invoice/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_project_invoice/doc/requirements-doc.txt sphinx: configuration: modules/project_invoice/doc/conf.py diff --git a/modules/project_invoice/doc/conf.py b/modules/project_invoice/doc/conf.py index 540e9c3069..b1f68ffa7c 100644 --- a/modules/project_invoice/doc/conf.py +++ b/modules/project_invoice/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/project_invoice/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/project_invoice/doc/requirements-doc.txt b/modules/project_invoice/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/project_invoice/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/project_plan/.readthedocs.yaml b/modules/project_plan/.readthedocs.yaml index 80c924d4a0..144a24295b 100644 --- a/modules/project_plan/.readthedocs.yaml +++ b/modules/project_plan/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_project_plan/doc/requirements-doc.txt sphinx: configuration: modules/project_plan/doc/conf.py diff --git a/modules/project_plan/doc/conf.py b/modules/project_plan/doc/conf.py index 540e9c3069..7b99ebc3ea 100644 --- a/modules/project_plan/doc/conf.py +++ b/modules/project_plan/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/project_plan/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/project_plan/doc/requirements-doc.txt b/modules/project_plan/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/project_plan/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/project_revenue/.readthedocs.yaml b/modules/project_revenue/.readthedocs.yaml index 2bdc725530..9cb1a08b40 100644 --- a/modules/project_revenue/.readthedocs.yaml +++ b/modules/project_revenue/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_project_revenue/doc/requirements-doc.txt sphinx: configuration: modules/project_revenue/doc/conf.py diff --git a/modules/project_revenue/doc/conf.py b/modules/project_revenue/doc/conf.py index 540e9c3069..80f9874221 100644 --- a/modules/project_revenue/doc/conf.py +++ b/modules/project_revenue/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/project_revenue/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/project_revenue/doc/requirements-doc.txt b/modules/project_revenue/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/project_revenue/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase/.readthedocs.yaml b/modules/purchase/.readthedocs.yaml index a9150e1d46..4e6313f884 100644 --- a/modules/purchase/.readthedocs.yaml +++ b/modules/purchase/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase/doc/requirements-doc.txt sphinx: configuration: modules/purchase/doc/conf.py diff --git a/modules/purchase/doc/conf.py b/modules/purchase/doc/conf.py index 540e9c3069..e6cccf420c 100644 --- a/modules/purchase/doc/conf.py +++ b/modules/purchase/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase/doc/requirements-doc.txt b/modules/purchase/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase_amendment/.readthedocs.yaml b/modules/purchase_amendment/.readthedocs.yaml index 83a4f35da6..a6d3125041 100644 --- a/modules/purchase_amendment/.readthedocs.yaml +++ b/modules/purchase_amendment/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase_amendment/doc/requirements-doc.txt sphinx: configuration: modules/purchase_amendment/doc/conf.py diff --git a/modules/purchase_amendment/doc/conf.py b/modules/purchase_amendment/doc/conf.py index 540e9c3069..d9d112d569 100644 --- a/modules/purchase_amendment/doc/conf.py +++ b/modules/purchase_amendment/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase_amendment/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase_amendment/doc/requirements-doc.txt b/modules/purchase_amendment/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase_amendment/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase_blanket_agreement/.readthedocs.yaml b/modules/purchase_blanket_agreement/.readthedocs.yaml index 001ff93b15..2b13166210 100644 --- a/modules/purchase_blanket_agreement/.readthedocs.yaml +++ b/modules/purchase_blanket_agreement/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase_blanket_agreement/doc/requirements-doc.txt sphinx: configuration: modules/purchase_blanket_agreement/doc/conf.py diff --git a/modules/purchase_blanket_agreement/doc/conf.py b/modules/purchase_blanket_agreement/doc/conf.py index 540e9c3069..4a5779e07a 100644 --- a/modules/purchase_blanket_agreement/doc/conf.py +++ b/modules/purchase_blanket_agreement/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase_blanket_agreement/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase_blanket_agreement/doc/requirements-doc.txt b/modules/purchase_blanket_agreement/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase_blanket_agreement/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase_history/.readthedocs.yaml b/modules/purchase_history/.readthedocs.yaml index a6c5a49952..284df42fa8 100644 --- a/modules/purchase_history/.readthedocs.yaml +++ b/modules/purchase_history/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase_history/doc/requirements-doc.txt sphinx: configuration: modules/purchase_history/doc/conf.py diff --git a/modules/purchase_history/doc/conf.py b/modules/purchase_history/doc/conf.py index 540e9c3069..ba73c9c9e2 100644 --- a/modules/purchase_history/doc/conf.py +++ b/modules/purchase_history/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase_history/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase_history/doc/requirements-doc.txt b/modules/purchase_history/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase_history/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase_invoice_line_standalone/.readthedocs.yaml b/modules/purchase_invoice_line_standalone/.readthedocs.yaml index eae2791dd8..f3c6092465 100644 --- a/modules/purchase_invoice_line_standalone/.readthedocs.yaml +++ b/modules/purchase_invoice_line_standalone/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase_invoice_line_standalone/doc/requirements-doc.txt sphinx: configuration: modules/purchase_invoice_line_standalone/doc/conf.py diff --git a/modules/purchase_invoice_line_standalone/doc/conf.py b/modules/purchase_invoice_line_standalone/doc/conf.py index 540e9c3069..9ad3810f12 100644 --- a/modules/purchase_invoice_line_standalone/doc/conf.py +++ b/modules/purchase_invoice_line_standalone/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase_invoice_line_standalone/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase_invoice_line_standalone/doc/requirements-doc.txt b/modules/purchase_invoice_line_standalone/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase_invoice_line_standalone/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase_price_list/.readthedocs.yaml b/modules/purchase_price_list/.readthedocs.yaml index 3ee50dcdb2..ec6ce40afc 100644 --- a/modules/purchase_price_list/.readthedocs.yaml +++ b/modules/purchase_price_list/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase_price_list/doc/requirements-doc.txt sphinx: configuration: modules/purchase_price_list/doc/conf.py diff --git a/modules/purchase_price_list/doc/conf.py b/modules/purchase_price_list/doc/conf.py index 540e9c3069..4e56a4895b 100644 --- a/modules/purchase_price_list/doc/conf.py +++ b/modules/purchase_price_list/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase_price_list/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase_price_list/doc/requirements-doc.txt b/modules/purchase_price_list/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase_price_list/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase_product_quantity/.readthedocs.yaml b/modules/purchase_product_quantity/.readthedocs.yaml index 51aceb07c3..6f989c8af3 100644 --- a/modules/purchase_product_quantity/.readthedocs.yaml +++ b/modules/purchase_product_quantity/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase_product_quantity/doc/requirements-doc.txt sphinx: configuration: modules/purchase_product_quantity/doc/conf.py diff --git a/modules/purchase_product_quantity/doc/conf.py b/modules/purchase_product_quantity/doc/conf.py index 540e9c3069..73f00dfc29 100644 --- a/modules/purchase_product_quantity/doc/conf.py +++ b/modules/purchase_product_quantity/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase_product_quantity/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase_product_quantity/doc/requirements-doc.txt b/modules/purchase_product_quantity/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase_product_quantity/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase_request/.readthedocs.yaml b/modules/purchase_request/.readthedocs.yaml index a6ef92ce78..8a19c0b1ef 100644 --- a/modules/purchase_request/.readthedocs.yaml +++ b/modules/purchase_request/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase_request/doc/requirements-doc.txt sphinx: configuration: modules/purchase_request/doc/conf.py diff --git a/modules/purchase_request/doc/conf.py b/modules/purchase_request/doc/conf.py index 540e9c3069..32edc2ce84 100644 --- a/modules/purchase_request/doc/conf.py +++ b/modules/purchase_request/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase_request/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase_request/doc/requirements-doc.txt b/modules/purchase_request/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase_request/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase_request_quotation/.readthedocs.yaml b/modules/purchase_request_quotation/.readthedocs.yaml index 3deb4d18bd..5ab5a7fe30 100644 --- a/modules/purchase_request_quotation/.readthedocs.yaml +++ b/modules/purchase_request_quotation/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase_request_quotation/doc/requirements-doc.txt sphinx: configuration: modules/purchase_request_quotation/doc/conf.py diff --git a/modules/purchase_request_quotation/doc/conf.py b/modules/purchase_request_quotation/doc/conf.py index 540e9c3069..179ca28abc 100644 --- a/modules/purchase_request_quotation/doc/conf.py +++ b/modules/purchase_request_quotation/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase_request_quotation/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase_request_quotation/doc/requirements-doc.txt b/modules/purchase_request_quotation/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase_request_quotation/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase_requisition/.readthedocs.yaml b/modules/purchase_requisition/.readthedocs.yaml index 1263763cfe..e600a63a4d 100644 --- a/modules/purchase_requisition/.readthedocs.yaml +++ b/modules/purchase_requisition/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase_requisition/doc/requirements-doc.txt sphinx: configuration: modules/purchase_requisition/doc/conf.py diff --git a/modules/purchase_requisition/doc/conf.py b/modules/purchase_requisition/doc/conf.py index 540e9c3069..41c021a2f6 100644 --- a/modules/purchase_requisition/doc/conf.py +++ b/modules/purchase_requisition/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase_requisition/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase_requisition/doc/requirements-doc.txt b/modules/purchase_requisition/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase_requisition/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase_secondary_unit/.readthedocs.yaml b/modules/purchase_secondary_unit/.readthedocs.yaml index 25c2123380..78e7c58fbc 100644 --- a/modules/purchase_secondary_unit/.readthedocs.yaml +++ b/modules/purchase_secondary_unit/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase_secondary_unit/doc/requirements-doc.txt sphinx: configuration: modules/purchase_secondary_unit/doc/conf.py diff --git a/modules/purchase_secondary_unit/doc/conf.py b/modules/purchase_secondary_unit/doc/conf.py index 540e9c3069..8c81b10d04 100644 --- a/modules/purchase_secondary_unit/doc/conf.py +++ b/modules/purchase_secondary_unit/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase_secondary_unit/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase_secondary_unit/doc/requirements-doc.txt b/modules/purchase_secondary_unit/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase_secondary_unit/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/purchase_shipment_cost/.readthedocs.yaml b/modules/purchase_shipment_cost/.readthedocs.yaml index 4005658b61..fd96904c4f 100644 --- a/modules/purchase_shipment_cost/.readthedocs.yaml +++ b/modules/purchase_shipment_cost/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_purchase_shipment_cost/doc/requirements-doc.txt sphinx: configuration: modules/purchase_shipment_cost/doc/conf.py diff --git a/modules/purchase_shipment_cost/doc/conf.py b/modules/purchase_shipment_cost/doc/conf.py index 540e9c3069..7f28bbe60b 100644 --- a/modules/purchase_shipment_cost/doc/conf.py +++ b/modules/purchase_shipment_cost/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/purchase_shipment_cost/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/purchase_shipment_cost/doc/requirements-doc.txt b/modules/purchase_shipment_cost/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/purchase_shipment_cost/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/quality/.readthedocs.yaml b/modules/quality/.readthedocs.yaml index 35660aa23a..f49c9231b5 100644 --- a/modules/quality/.readthedocs.yaml +++ b/modules/quality/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_quality/doc/requirements-doc.txt sphinx: configuration: modules/quality/doc/conf.py diff --git a/modules/quality/doc/conf.py b/modules/quality/doc/conf.py index 540e9c3069..0a3f686fb8 100644 --- a/modules/quality/doc/conf.py +++ b/modules/quality/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/quality/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/quality/doc/requirements-doc.txt b/modules/quality/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/quality/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale/.readthedocs.yaml b/modules/sale/.readthedocs.yaml index c06121462e..47d7a51d57 100644 --- a/modules/sale/.readthedocs.yaml +++ b/modules/sale/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale/doc/requirements-doc.txt sphinx: configuration: modules/sale/doc/conf.py diff --git a/modules/sale/doc/conf.py b/modules/sale/doc/conf.py index 540e9c3069..c2c8519200 100644 --- a/modules/sale/doc/conf.py +++ b/modules/sale/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale/doc/requirements-doc.txt b/modules/sale/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_advance_payment/.readthedocs.yaml b/modules/sale_advance_payment/.readthedocs.yaml index d5313dc44f..cbb2243fea 100644 --- a/modules/sale_advance_payment/.readthedocs.yaml +++ b/modules/sale_advance_payment/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_advance_payment/doc/requirements-doc.txt sphinx: configuration: modules/sale_advance_payment/doc/conf.py diff --git a/modules/sale_advance_payment/doc/conf.py b/modules/sale_advance_payment/doc/conf.py index 540e9c3069..141a2b46d7 100644 --- a/modules/sale_advance_payment/doc/conf.py +++ b/modules/sale_advance_payment/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_advance_payment/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_advance_payment/doc/requirements-doc.txt b/modules/sale_advance_payment/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_advance_payment/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_amendment/.readthedocs.yaml b/modules/sale_amendment/.readthedocs.yaml index 69637d1f20..d6b0b100c0 100644 --- a/modules/sale_amendment/.readthedocs.yaml +++ b/modules/sale_amendment/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_amendment/doc/requirements-doc.txt sphinx: configuration: modules/sale_amendment/doc/conf.py diff --git a/modules/sale_amendment/doc/conf.py b/modules/sale_amendment/doc/conf.py index 540e9c3069..180b30637e 100644 --- a/modules/sale_amendment/doc/conf.py +++ b/modules/sale_amendment/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_amendment/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_amendment/doc/requirements-doc.txt b/modules/sale_amendment/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_amendment/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_blanket_agreement/.readthedocs.yaml b/modules/sale_blanket_agreement/.readthedocs.yaml index 4a1f473cda..e94a9c182f 100644 --- a/modules/sale_blanket_agreement/.readthedocs.yaml +++ b/modules/sale_blanket_agreement/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_blanket_agreement/doc/requirements-doc.txt sphinx: configuration: modules/sale_blanket_agreement/doc/conf.py diff --git a/modules/sale_blanket_agreement/doc/conf.py b/modules/sale_blanket_agreement/doc/conf.py index 540e9c3069..1ded7c395b 100644 --- a/modules/sale_blanket_agreement/doc/conf.py +++ b/modules/sale_blanket_agreement/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_blanket_agreement/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_blanket_agreement/doc/requirements-doc.txt b/modules/sale_blanket_agreement/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_blanket_agreement/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_complaint/.readthedocs.yaml b/modules/sale_complaint/.readthedocs.yaml index 8fb61b8f24..4e874d078f 100644 --- a/modules/sale_complaint/.readthedocs.yaml +++ b/modules/sale_complaint/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_complaint/doc/requirements-doc.txt sphinx: configuration: modules/sale_complaint/doc/conf.py diff --git a/modules/sale_complaint/doc/conf.py b/modules/sale_complaint/doc/conf.py index 540e9c3069..bbecf00cb5 100644 --- a/modules/sale_complaint/doc/conf.py +++ b/modules/sale_complaint/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_complaint/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_complaint/doc/requirements-doc.txt b/modules/sale_complaint/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_complaint/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_credit_limit/.readthedocs.yaml b/modules/sale_credit_limit/.readthedocs.yaml index 6067672ea5..567cd33053 100644 --- a/modules/sale_credit_limit/.readthedocs.yaml +++ b/modules/sale_credit_limit/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_credit_limit/doc/requirements-doc.txt sphinx: configuration: modules/sale_credit_limit/doc/conf.py diff --git a/modules/sale_credit_limit/doc/conf.py b/modules/sale_credit_limit/doc/conf.py index 540e9c3069..a95e2fcc40 100644 --- a/modules/sale_credit_limit/doc/conf.py +++ b/modules/sale_credit_limit/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_credit_limit/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_credit_limit/doc/requirements-doc.txt b/modules/sale_credit_limit/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_credit_limit/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_discount/.readthedocs.yaml b/modules/sale_discount/.readthedocs.yaml index f18b703003..2c54e81c85 100644 --- a/modules/sale_discount/.readthedocs.yaml +++ b/modules/sale_discount/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_discount/doc/requirements-doc.txt sphinx: configuration: modules/sale_discount/doc/conf.py diff --git a/modules/sale_discount/doc/conf.py b/modules/sale_discount/doc/conf.py index 540e9c3069..b0112c187e 100644 --- a/modules/sale_discount/doc/conf.py +++ b/modules/sale_discount/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_discount/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_discount/doc/requirements-doc.txt b/modules/sale_discount/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_discount/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_extra/.readthedocs.yaml b/modules/sale_extra/.readthedocs.yaml index c9ddf5aa74..209605e4c0 100644 --- a/modules/sale_extra/.readthedocs.yaml +++ b/modules/sale_extra/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_extra/doc/requirements-doc.txt sphinx: configuration: modules/sale_extra/doc/conf.py diff --git a/modules/sale_extra/doc/conf.py b/modules/sale_extra/doc/conf.py index 540e9c3069..feab55d813 100644 --- a/modules/sale_extra/doc/conf.py +++ b/modules/sale_extra/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_extra/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_extra/doc/requirements-doc.txt b/modules/sale_extra/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_extra/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_gift_card/.readthedocs.yaml b/modules/sale_gift_card/.readthedocs.yaml index 1573754286..0438ee6b1e 100644 --- a/modules/sale_gift_card/.readthedocs.yaml +++ b/modules/sale_gift_card/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_gift_card/doc/requirements-doc.txt sphinx: configuration: modules/sale_gift_card/doc/conf.py diff --git a/modules/sale_gift_card/doc/conf.py b/modules/sale_gift_card/doc/conf.py index 540e9c3069..d89abd04e8 100644 --- a/modules/sale_gift_card/doc/conf.py +++ b/modules/sale_gift_card/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_gift_card/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_gift_card/doc/requirements-doc.txt b/modules/sale_gift_card/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_gift_card/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_history/.readthedocs.yaml b/modules/sale_history/.readthedocs.yaml index da7dc9ce02..6104c50df4 100644 --- a/modules/sale_history/.readthedocs.yaml +++ b/modules/sale_history/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_history/doc/requirements-doc.txt sphinx: configuration: modules/sale_history/doc/conf.py diff --git a/modules/sale_history/doc/conf.py b/modules/sale_history/doc/conf.py index 540e9c3069..7033e1e105 100644 --- a/modules/sale_history/doc/conf.py +++ b/modules/sale_history/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_history/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_history/doc/requirements-doc.txt b/modules/sale_history/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_history/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_invoice_date/.readthedocs.yaml b/modules/sale_invoice_date/.readthedocs.yaml index eb4b8282d3..fbaedac83f 100644 --- a/modules/sale_invoice_date/.readthedocs.yaml +++ b/modules/sale_invoice_date/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_invoice_date/doc/requirements-doc.txt sphinx: configuration: modules/sale_invoice_date/doc/conf.py diff --git a/modules/sale_invoice_date/doc/conf.py b/modules/sale_invoice_date/doc/conf.py index 540e9c3069..0ada4faa12 100644 --- a/modules/sale_invoice_date/doc/conf.py +++ b/modules/sale_invoice_date/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_invoice_date/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_invoice_date/doc/requirements-doc.txt b/modules/sale_invoice_date/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_invoice_date/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_invoice_grouping/.readthedocs.yaml b/modules/sale_invoice_grouping/.readthedocs.yaml index 791e4197b8..cc3af542d7 100644 --- a/modules/sale_invoice_grouping/.readthedocs.yaml +++ b/modules/sale_invoice_grouping/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_invoice_grouping/doc/requirements-doc.txt sphinx: configuration: modules/sale_invoice_grouping/doc/conf.py diff --git a/modules/sale_invoice_grouping/doc/conf.py b/modules/sale_invoice_grouping/doc/conf.py index 540e9c3069..2063d69e69 100644 --- a/modules/sale_invoice_grouping/doc/conf.py +++ b/modules/sale_invoice_grouping/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_invoice_grouping/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_invoice_grouping/doc/requirements-doc.txt b/modules/sale_invoice_grouping/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_invoice_grouping/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_opportunity/.readthedocs.yaml b/modules/sale_opportunity/.readthedocs.yaml index 3ebd900e14..a71f63d738 100644 --- a/modules/sale_opportunity/.readthedocs.yaml +++ b/modules/sale_opportunity/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_opportunity/doc/requirements-doc.txt sphinx: configuration: modules/sale_opportunity/doc/conf.py diff --git a/modules/sale_opportunity/doc/conf.py b/modules/sale_opportunity/doc/conf.py index 540e9c3069..6afa3e9d36 100644 --- a/modules/sale_opportunity/doc/conf.py +++ b/modules/sale_opportunity/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_opportunity/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_opportunity/doc/requirements-doc.txt b/modules/sale_opportunity/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_opportunity/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_payment/.readthedocs.yaml b/modules/sale_payment/.readthedocs.yaml index f509e1c491..a364a2e67c 100644 --- a/modules/sale_payment/.readthedocs.yaml +++ b/modules/sale_payment/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_payment/doc/requirements-doc.txt sphinx: configuration: modules/sale_payment/doc/conf.py diff --git a/modules/sale_payment/doc/conf.py b/modules/sale_payment/doc/conf.py index 540e9c3069..d64bbfbd08 100644 --- a/modules/sale_payment/doc/conf.py +++ b/modules/sale_payment/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_payment/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_payment/doc/requirements-doc.txt b/modules/sale_payment/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_payment/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_point/.readthedocs.yaml b/modules/sale_point/.readthedocs.yaml index d2b987d2ce..5e62a6f8aa 100644 --- a/modules/sale_point/.readthedocs.yaml +++ b/modules/sale_point/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_point/doc/requirements-doc.txt sphinx: configuration: modules/sale_point/doc/conf.py diff --git a/modules/sale_point/doc/conf.py b/modules/sale_point/doc/conf.py index 540e9c3069..7d0bdc6612 100644 --- a/modules/sale_point/doc/conf.py +++ b/modules/sale_point/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_point/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_point/doc/requirements-doc.txt b/modules/sale_point/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_point/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_price_list/.readthedocs.yaml b/modules/sale_price_list/.readthedocs.yaml index 45b21091c1..54b5373adc 100644 --- a/modules/sale_price_list/.readthedocs.yaml +++ b/modules/sale_price_list/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_price_list/doc/requirements-doc.txt sphinx: configuration: modules/sale_price_list/doc/conf.py diff --git a/modules/sale_price_list/doc/conf.py b/modules/sale_price_list/doc/conf.py index 540e9c3069..169950d712 100644 --- a/modules/sale_price_list/doc/conf.py +++ b/modules/sale_price_list/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_price_list/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_price_list/doc/requirements-doc.txt b/modules/sale_price_list/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_price_list/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_product_customer/.readthedocs.yaml b/modules/sale_product_customer/.readthedocs.yaml index 28903b720e..eae323edc5 100644 --- a/modules/sale_product_customer/.readthedocs.yaml +++ b/modules/sale_product_customer/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_product_customer/doc/requirements-doc.txt sphinx: configuration: modules/sale_product_customer/doc/conf.py diff --git a/modules/sale_product_customer/doc/conf.py b/modules/sale_product_customer/doc/conf.py index 540e9c3069..ac912beebd 100644 --- a/modules/sale_product_customer/doc/conf.py +++ b/modules/sale_product_customer/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_product_customer/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_product_customer/doc/requirements-doc.txt b/modules/sale_product_customer/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_product_customer/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_product_quantity/.readthedocs.yaml b/modules/sale_product_quantity/.readthedocs.yaml index a95f5b6db8..0082cf9e38 100644 --- a/modules/sale_product_quantity/.readthedocs.yaml +++ b/modules/sale_product_quantity/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_product_quantity/doc/requirements-doc.txt sphinx: configuration: modules/sale_product_quantity/doc/conf.py diff --git a/modules/sale_product_quantity/doc/conf.py b/modules/sale_product_quantity/doc/conf.py index 540e9c3069..47f91abe22 100644 --- a/modules/sale_product_quantity/doc/conf.py +++ b/modules/sale_product_quantity/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_product_quantity/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_product_quantity/doc/requirements-doc.txt b/modules/sale_product_quantity/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_product_quantity/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_product_recommendation/.readthedocs.yaml b/modules/sale_product_recommendation/.readthedocs.yaml index 33d3fa2973..a2c37ab065 100644 --- a/modules/sale_product_recommendation/.readthedocs.yaml +++ b/modules/sale_product_recommendation/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_product_recommendation/doc/requirements-doc.txt sphinx: configuration: modules/sale_product_recommendation/doc/conf.py diff --git a/modules/sale_product_recommendation/doc/conf.py b/modules/sale_product_recommendation/doc/conf.py index 540e9c3069..7935ae52ca 100644 --- a/modules/sale_product_recommendation/doc/conf.py +++ b/modules/sale_product_recommendation/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_product_recommendation/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_product_recommendation/doc/requirements-doc.txt b/modules/sale_product_recommendation/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_product_recommendation/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_product_recommendation_association_rule/.readthedocs.yaml b/modules/sale_product_recommendation_association_rule/.readthedocs.yaml index 17da34b46f..91ad49e328 100644 --- a/modules/sale_product_recommendation_association_rule/.readthedocs.yaml +++ b/modules/sale_product_recommendation_association_rule/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_product_recommendation_association_rule/doc/requirements-doc.txt sphinx: configuration: modules/sale_product_recommendation_association_rule/doc/conf.py diff --git a/modules/sale_product_recommendation_association_rule/doc/conf.py b/modules/sale_product_recommendation_association_rule/doc/conf.py index 540e9c3069..afcfbe2aba 100644 --- a/modules/sale_product_recommendation_association_rule/doc/conf.py +++ b/modules/sale_product_recommendation_association_rule/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_product_recommendation_association_rule/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_product_recommendation_association_rule/doc/requirements-doc.txt b/modules/sale_product_recommendation_association_rule/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_product_recommendation_association_rule/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_promotion/.readthedocs.yaml b/modules/sale_promotion/.readthedocs.yaml index 914848630c..cf95e49500 100644 --- a/modules/sale_promotion/.readthedocs.yaml +++ b/modules/sale_promotion/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_promotion/doc/requirements-doc.txt sphinx: configuration: modules/sale_promotion/doc/conf.py diff --git a/modules/sale_promotion/doc/conf.py b/modules/sale_promotion/doc/conf.py index 540e9c3069..13477acf3d 100644 --- a/modules/sale_promotion/doc/conf.py +++ b/modules/sale_promotion/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_promotion/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_promotion/doc/requirements-doc.txt b/modules/sale_promotion/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_promotion/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_promotion_coupon/.readthedocs.yaml b/modules/sale_promotion_coupon/.readthedocs.yaml index 30682a53ed..323dac6090 100644 --- a/modules/sale_promotion_coupon/.readthedocs.yaml +++ b/modules/sale_promotion_coupon/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_promotion_coupon/doc/requirements-doc.txt sphinx: configuration: modules/sale_promotion_coupon/doc/conf.py diff --git a/modules/sale_promotion_coupon/doc/conf.py b/modules/sale_promotion_coupon/doc/conf.py index 540e9c3069..defb691729 100644 --- a/modules/sale_promotion_coupon/doc/conf.py +++ b/modules/sale_promotion_coupon/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_promotion_coupon/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_promotion_coupon/doc/requirements-doc.txt b/modules/sale_promotion_coupon/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_promotion_coupon/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_promotion_coupon_payment/.readthedocs.yaml b/modules/sale_promotion_coupon_payment/.readthedocs.yaml index 91c9d414a8..f05d995416 100644 --- a/modules/sale_promotion_coupon_payment/.readthedocs.yaml +++ b/modules/sale_promotion_coupon_payment/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_promotion_coupon_payment/doc/requirements-doc.txt sphinx: configuration: modules/sale_promotion_coupon_payment/doc/conf.py diff --git a/modules/sale_promotion_coupon_payment/doc/conf.py b/modules/sale_promotion_coupon_payment/doc/conf.py index 540e9c3069..aa5185b640 100644 --- a/modules/sale_promotion_coupon_payment/doc/conf.py +++ b/modules/sale_promotion_coupon_payment/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_promotion_coupon_payment/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_promotion_coupon_payment/doc/requirements-doc.txt b/modules/sale_promotion_coupon_payment/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_promotion_coupon_payment/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_secondary_unit/.readthedocs.yaml b/modules/sale_secondary_unit/.readthedocs.yaml index 3f6a1982d1..a2688678bd 100644 --- a/modules/sale_secondary_unit/.readthedocs.yaml +++ b/modules/sale_secondary_unit/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_secondary_unit/doc/requirements-doc.txt sphinx: configuration: modules/sale_secondary_unit/doc/conf.py diff --git a/modules/sale_secondary_unit/doc/conf.py b/modules/sale_secondary_unit/doc/conf.py index 540e9c3069..a85072487f 100644 --- a/modules/sale_secondary_unit/doc/conf.py +++ b/modules/sale_secondary_unit/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_secondary_unit/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_secondary_unit/doc/requirements-doc.txt b/modules/sale_secondary_unit/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_secondary_unit/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_shipment_cost/.readthedocs.yaml b/modules/sale_shipment_cost/.readthedocs.yaml index c0a400fb97..d0135156a5 100644 --- a/modules/sale_shipment_cost/.readthedocs.yaml +++ b/modules/sale_shipment_cost/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_shipment_cost/doc/requirements-doc.txt sphinx: configuration: modules/sale_shipment_cost/doc/conf.py diff --git a/modules/sale_shipment_cost/doc/conf.py b/modules/sale_shipment_cost/doc/conf.py index 540e9c3069..8e2758effc 100644 --- a/modules/sale_shipment_cost/doc/conf.py +++ b/modules/sale_shipment_cost/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_shipment_cost/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_shipment_cost/doc/requirements-doc.txt b/modules/sale_shipment_cost/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_shipment_cost/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_shipment_grouping/.readthedocs.yaml b/modules/sale_shipment_grouping/.readthedocs.yaml index 6fc526a6ca..73d1b3ed54 100644 --- a/modules/sale_shipment_grouping/.readthedocs.yaml +++ b/modules/sale_shipment_grouping/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_shipment_grouping/doc/requirements-doc.txt sphinx: configuration: modules/sale_shipment_grouping/doc/conf.py diff --git a/modules/sale_shipment_grouping/doc/conf.py b/modules/sale_shipment_grouping/doc/conf.py index 540e9c3069..ea9337fabd 100644 --- a/modules/sale_shipment_grouping/doc/conf.py +++ b/modules/sale_shipment_grouping/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_shipment_grouping/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_shipment_grouping/doc/requirements-doc.txt b/modules/sale_shipment_grouping/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_shipment_grouping/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_shipment_tolerance/.readthedocs.yaml b/modules/sale_shipment_tolerance/.readthedocs.yaml index a622fe3ce5..ea32ac65fb 100644 --- a/modules/sale_shipment_tolerance/.readthedocs.yaml +++ b/modules/sale_shipment_tolerance/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_shipment_tolerance/doc/requirements-doc.txt sphinx: configuration: modules/sale_shipment_tolerance/doc/conf.py diff --git a/modules/sale_shipment_tolerance/doc/conf.py b/modules/sale_shipment_tolerance/doc/conf.py index 540e9c3069..8dee18de53 100644 --- a/modules/sale_shipment_tolerance/doc/conf.py +++ b/modules/sale_shipment_tolerance/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_shipment_tolerance/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_shipment_tolerance/doc/requirements-doc.txt b/modules/sale_shipment_tolerance/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_shipment_tolerance/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_stock_quantity/.readthedocs.yaml b/modules/sale_stock_quantity/.readthedocs.yaml index 71f79b0fe5..43c0137839 100644 --- a/modules/sale_stock_quantity/.readthedocs.yaml +++ b/modules/sale_stock_quantity/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_stock_quantity/doc/requirements-doc.txt sphinx: configuration: modules/sale_stock_quantity/doc/conf.py diff --git a/modules/sale_stock_quantity/doc/conf.py b/modules/sale_stock_quantity/doc/conf.py index 540e9c3069..38c46fa891 100644 --- a/modules/sale_stock_quantity/doc/conf.py +++ b/modules/sale_stock_quantity/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_stock_quantity/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_stock_quantity/doc/requirements-doc.txt b/modules/sale_stock_quantity/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_stock_quantity/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_subscription/.readthedocs.yaml b/modules/sale_subscription/.readthedocs.yaml index 34a37822b9..6bdaf2a272 100644 --- a/modules/sale_subscription/.readthedocs.yaml +++ b/modules/sale_subscription/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_subscription/doc/requirements-doc.txt sphinx: configuration: modules/sale_subscription/doc/conf.py diff --git a/modules/sale_subscription/doc/conf.py b/modules/sale_subscription/doc/conf.py index 540e9c3069..7c411fcaf8 100644 --- a/modules/sale_subscription/doc/conf.py +++ b/modules/sale_subscription/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_subscription/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_subscription/doc/requirements-doc.txt b/modules/sale_subscription/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_subscription/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_subscription_asset/.readthedocs.yaml b/modules/sale_subscription_asset/.readthedocs.yaml index 882ea22174..ecedad6e5f 100644 --- a/modules/sale_subscription_asset/.readthedocs.yaml +++ b/modules/sale_subscription_asset/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_subscription_asset/doc/requirements-doc.txt sphinx: configuration: modules/sale_subscription_asset/doc/conf.py diff --git a/modules/sale_subscription_asset/doc/conf.py b/modules/sale_subscription_asset/doc/conf.py index 540e9c3069..ac9ebd31ac 100644 --- a/modules/sale_subscription_asset/doc/conf.py +++ b/modules/sale_subscription_asset/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_subscription_asset/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_subscription_asset/doc/requirements-doc.txt b/modules/sale_subscription_asset/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_subscription_asset/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_supply/.readthedocs.yaml b/modules/sale_supply/.readthedocs.yaml index b5c34ce34d..a8db3860df 100644 --- a/modules/sale_supply/.readthedocs.yaml +++ b/modules/sale_supply/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_supply/doc/requirements-doc.txt sphinx: configuration: modules/sale_supply/doc/conf.py diff --git a/modules/sale_supply/doc/conf.py b/modules/sale_supply/doc/conf.py index 540e9c3069..b7e649089f 100644 --- a/modules/sale_supply/doc/conf.py +++ b/modules/sale_supply/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_supply/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_supply/doc/requirements-doc.txt b/modules/sale_supply/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_supply/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_supply_drop_shipment/.readthedocs.yaml b/modules/sale_supply_drop_shipment/.readthedocs.yaml index 2f638cd1c1..5cf62b35aa 100644 --- a/modules/sale_supply_drop_shipment/.readthedocs.yaml +++ b/modules/sale_supply_drop_shipment/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_supply_drop_shipment/doc/requirements-doc.txt sphinx: configuration: modules/sale_supply_drop_shipment/doc/conf.py diff --git a/modules/sale_supply_drop_shipment/doc/conf.py b/modules/sale_supply_drop_shipment/doc/conf.py index 540e9c3069..7bd5a83b91 100644 --- a/modules/sale_supply_drop_shipment/doc/conf.py +++ b/modules/sale_supply_drop_shipment/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_supply_drop_shipment/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_supply_drop_shipment/doc/requirements-doc.txt b/modules/sale_supply_drop_shipment/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_supply_drop_shipment/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/sale_supply_production/.readthedocs.yaml b/modules/sale_supply_production/.readthedocs.yaml index 5251c0998c..cd13dde8fd 100644 --- a/modules/sale_supply_production/.readthedocs.yaml +++ b/modules/sale_supply_production/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_sale_supply_production/doc/requirements-doc.txt sphinx: configuration: modules/sale_supply_production/doc/conf.py diff --git a/modules/sale_supply_production/doc/conf.py b/modules/sale_supply_production/doc/conf.py index 540e9c3069..aed4b355ee 100644 --- a/modules/sale_supply_production/doc/conf.py +++ b/modules/sale_supply_production/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/sale_supply_production/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/sale_supply_production/doc/requirements-doc.txt b/modules/sale_supply_production/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/sale_supply_production/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock/.readthedocs.yaml b/modules/stock/.readthedocs.yaml index 85c765816c..4bdf243687 100644 --- a/modules/stock/.readthedocs.yaml +++ b/modules/stock/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock/doc/requirements-doc.txt sphinx: configuration: modules/stock/doc/conf.py diff --git a/modules/stock/doc/conf.py b/modules/stock/doc/conf.py index 540e9c3069..90406ab70c 100644 --- a/modules/stock/doc/conf.py +++ b/modules/stock/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock/doc/requirements-doc.txt b/modules/stock/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_assign_manual/.readthedocs.yaml b/modules/stock_assign_manual/.readthedocs.yaml index ac2d491dfe..398813fd32 100644 --- a/modules/stock_assign_manual/.readthedocs.yaml +++ b/modules/stock_assign_manual/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_assign_manual/doc/requirements-doc.txt sphinx: configuration: modules/stock_assign_manual/doc/conf.py diff --git a/modules/stock_assign_manual/doc/conf.py b/modules/stock_assign_manual/doc/conf.py index 540e9c3069..bc9637e1ed 100644 --- a/modules/stock_assign_manual/doc/conf.py +++ b/modules/stock_assign_manual/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_assign_manual/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_assign_manual/doc/requirements-doc.txt b/modules/stock_assign_manual/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_assign_manual/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_consignment/.readthedocs.yaml b/modules/stock_consignment/.readthedocs.yaml index 7c5435b9da..602d2ce71b 100644 --- a/modules/stock_consignment/.readthedocs.yaml +++ b/modules/stock_consignment/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_consignment/doc/requirements-doc.txt sphinx: configuration: modules/stock_consignment/doc/conf.py diff --git a/modules/stock_consignment/doc/conf.py b/modules/stock_consignment/doc/conf.py index 540e9c3069..6c0b2e5c34 100644 --- a/modules/stock_consignment/doc/conf.py +++ b/modules/stock_consignment/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_consignment/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_consignment/doc/requirements-doc.txt b/modules/stock_consignment/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_consignment/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_forecast/.readthedocs.yaml b/modules/stock_forecast/.readthedocs.yaml index 4bda2f23af..14fc5749ac 100644 --- a/modules/stock_forecast/.readthedocs.yaml +++ b/modules/stock_forecast/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_forecast/doc/requirements-doc.txt sphinx: configuration: modules/stock_forecast/doc/conf.py diff --git a/modules/stock_forecast/doc/conf.py b/modules/stock_forecast/doc/conf.py index 540e9c3069..398520fc71 100644 --- a/modules/stock_forecast/doc/conf.py +++ b/modules/stock_forecast/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_forecast/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_forecast/doc/requirements-doc.txt b/modules/stock_forecast/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_forecast/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_inventory_location/.readthedocs.yaml b/modules/stock_inventory_location/.readthedocs.yaml index ca3f545757..c3aea5acb1 100644 --- a/modules/stock_inventory_location/.readthedocs.yaml +++ b/modules/stock_inventory_location/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_inventory_location/doc/requirements-doc.txt sphinx: configuration: modules/stock_inventory_location/doc/conf.py diff --git a/modules/stock_inventory_location/doc/conf.py b/modules/stock_inventory_location/doc/conf.py index 540e9c3069..1c724d699d 100644 --- a/modules/stock_inventory_location/doc/conf.py +++ b/modules/stock_inventory_location/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_inventory_location/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_inventory_location/doc/requirements-doc.txt b/modules/stock_inventory_location/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_inventory_location/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_location_move/.readthedocs.yaml b/modules/stock_location_move/.readthedocs.yaml index 41af3ef67a..bacc94cde0 100644 --- a/modules/stock_location_move/.readthedocs.yaml +++ b/modules/stock_location_move/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_location_move/doc/requirements-doc.txt sphinx: configuration: modules/stock_location_move/doc/conf.py diff --git a/modules/stock_location_move/doc/conf.py b/modules/stock_location_move/doc/conf.py index 540e9c3069..17d2b07089 100644 --- a/modules/stock_location_move/doc/conf.py +++ b/modules/stock_location_move/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_location_move/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_location_move/doc/requirements-doc.txt b/modules/stock_location_move/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_location_move/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_location_sequence/.readthedocs.yaml b/modules/stock_location_sequence/.readthedocs.yaml index b5bcbab912..449b20d336 100644 --- a/modules/stock_location_sequence/.readthedocs.yaml +++ b/modules/stock_location_sequence/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_location_sequence/doc/requirements-doc.txt sphinx: configuration: modules/stock_location_sequence/doc/conf.py diff --git a/modules/stock_location_sequence/doc/conf.py b/modules/stock_location_sequence/doc/conf.py index 540e9c3069..510aa208be 100644 --- a/modules/stock_location_sequence/doc/conf.py +++ b/modules/stock_location_sequence/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_location_sequence/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_location_sequence/doc/requirements-doc.txt b/modules/stock_location_sequence/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_location_sequence/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_lot/.readthedocs.yaml b/modules/stock_lot/.readthedocs.yaml index 60007034d9..ae883b383c 100644 --- a/modules/stock_lot/.readthedocs.yaml +++ b/modules/stock_lot/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_lot/doc/requirements-doc.txt sphinx: configuration: modules/stock_lot/doc/conf.py diff --git a/modules/stock_lot/doc/conf.py b/modules/stock_lot/doc/conf.py index 540e9c3069..ede04e87ee 100644 --- a/modules/stock_lot/doc/conf.py +++ b/modules/stock_lot/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_lot/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_lot/doc/requirements-doc.txt b/modules/stock_lot/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_lot/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_lot_sled/.readthedocs.yaml b/modules/stock_lot_sled/.readthedocs.yaml index 923d6a96ee..a3493af74c 100644 --- a/modules/stock_lot_sled/.readthedocs.yaml +++ b/modules/stock_lot_sled/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_lot_sled/doc/requirements-doc.txt sphinx: configuration: modules/stock_lot_sled/doc/conf.py diff --git a/modules/stock_lot_sled/doc/conf.py b/modules/stock_lot_sled/doc/conf.py index 540e9c3069..9b8654ec2d 100644 --- a/modules/stock_lot_sled/doc/conf.py +++ b/modules/stock_lot_sled/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_lot_sled/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_lot_sled/doc/requirements-doc.txt b/modules/stock_lot_sled/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_lot_sled/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_lot_unit/.readthedocs.yaml b/modules/stock_lot_unit/.readthedocs.yaml index 4c45353cb9..e8ee946e5c 100644 --- a/modules/stock_lot_unit/.readthedocs.yaml +++ b/modules/stock_lot_unit/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_lot_unit/doc/requirements-doc.txt sphinx: configuration: modules/stock_lot_unit/doc/conf.py diff --git a/modules/stock_lot_unit/doc/conf.py b/modules/stock_lot_unit/doc/conf.py index 540e9c3069..2ec149be52 100644 --- a/modules/stock_lot_unit/doc/conf.py +++ b/modules/stock_lot_unit/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_lot_unit/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_lot_unit/doc/requirements-doc.txt b/modules/stock_lot_unit/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_lot_unit/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_package/.readthedocs.yaml b/modules/stock_package/.readthedocs.yaml index 48907b9e24..e95db45bb4 100644 --- a/modules/stock_package/.readthedocs.yaml +++ b/modules/stock_package/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_package/doc/requirements-doc.txt sphinx: configuration: modules/stock_package/doc/conf.py diff --git a/modules/stock_package/doc/conf.py b/modules/stock_package/doc/conf.py index 540e9c3069..91ab4944ad 100644 --- a/modules/stock_package/doc/conf.py +++ b/modules/stock_package/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_package/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_package/doc/requirements-doc.txt b/modules/stock_package/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_package/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_package_shipping/.readthedocs.yaml b/modules/stock_package_shipping/.readthedocs.yaml index 5563070903..5fd586d6f4 100644 --- a/modules/stock_package_shipping/.readthedocs.yaml +++ b/modules/stock_package_shipping/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_package_shipping/doc/requirements-doc.txt sphinx: configuration: modules/stock_package_shipping/doc/conf.py diff --git a/modules/stock_package_shipping/doc/conf.py b/modules/stock_package_shipping/doc/conf.py index 540e9c3069..4967d2da56 100644 --- a/modules/stock_package_shipping/doc/conf.py +++ b/modules/stock_package_shipping/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_package_shipping/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_package_shipping/doc/requirements-doc.txt b/modules/stock_package_shipping/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_package_shipping/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_package_shipping_dpd/.readthedocs.yaml b/modules/stock_package_shipping_dpd/.readthedocs.yaml index 3924b962e0..687bdee787 100644 --- a/modules/stock_package_shipping_dpd/.readthedocs.yaml +++ b/modules/stock_package_shipping_dpd/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_package_shipping_dpd/doc/requirements-doc.txt sphinx: configuration: modules/stock_package_shipping_dpd/doc/conf.py diff --git a/modules/stock_package_shipping_dpd/doc/conf.py b/modules/stock_package_shipping_dpd/doc/conf.py index 540e9c3069..20ab563a6a 100644 --- a/modules/stock_package_shipping_dpd/doc/conf.py +++ b/modules/stock_package_shipping_dpd/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_package_shipping_dpd/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_package_shipping_dpd/doc/requirements-doc.txt b/modules/stock_package_shipping_dpd/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_package_shipping_dpd/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_package_shipping_mygls/.readthedocs.yaml b/modules/stock_package_shipping_mygls/.readthedocs.yaml index e69de086fd..d55b1c2bb7 100644 --- a/modules/stock_package_shipping_mygls/.readthedocs.yaml +++ b/modules/stock_package_shipping_mygls/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_package_shipping_mygls/doc/requirements-doc.txt sphinx: configuration: modules/stock_package_shipping_mygls/doc/conf.py diff --git a/modules/stock_package_shipping_mygls/doc/conf.py b/modules/stock_package_shipping_mygls/doc/conf.py index 540e9c3069..be5445b498 100644 --- a/modules/stock_package_shipping_mygls/doc/conf.py +++ b/modules/stock_package_shipping_mygls/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_package_shipping_mygls/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_package_shipping_mygls/doc/requirements-doc.txt b/modules/stock_package_shipping_mygls/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_package_shipping_mygls/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_package_shipping_sendcloud/.readthedocs.yaml b/modules/stock_package_shipping_sendcloud/.readthedocs.yaml index c724aea0bb..32428b6bf1 100644 --- a/modules/stock_package_shipping_sendcloud/.readthedocs.yaml +++ b/modules/stock_package_shipping_sendcloud/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_package_shipping_sendcloud/doc/requirements-doc.txt sphinx: configuration: modules/stock_package_shipping_sendcloud/doc/conf.py diff --git a/modules/stock_package_shipping_sendcloud/doc/conf.py b/modules/stock_package_shipping_sendcloud/doc/conf.py index 540e9c3069..ee221682ab 100644 --- a/modules/stock_package_shipping_sendcloud/doc/conf.py +++ b/modules/stock_package_shipping_sendcloud/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_package_shipping_sendcloud/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_package_shipping_sendcloud/doc/requirements-doc.txt b/modules/stock_package_shipping_sendcloud/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_package_shipping_sendcloud/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_package_shipping_ups/.readthedocs.yaml b/modules/stock_package_shipping_ups/.readthedocs.yaml index 38d79e516c..b23d24c03b 100644 --- a/modules/stock_package_shipping_ups/.readthedocs.yaml +++ b/modules/stock_package_shipping_ups/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_package_shipping_ups/doc/requirements-doc.txt sphinx: configuration: modules/stock_package_shipping_ups/doc/conf.py diff --git a/modules/stock_package_shipping_ups/doc/conf.py b/modules/stock_package_shipping_ups/doc/conf.py index 540e9c3069..8c0381049b 100644 --- a/modules/stock_package_shipping_ups/doc/conf.py +++ b/modules/stock_package_shipping_ups/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_package_shipping_ups/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_package_shipping_ups/doc/requirements-doc.txt b/modules/stock_package_shipping_ups/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_package_shipping_ups/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_product_location/.readthedocs.yaml b/modules/stock_product_location/.readthedocs.yaml index 4fa5c077f8..839b796756 100644 --- a/modules/stock_product_location/.readthedocs.yaml +++ b/modules/stock_product_location/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_product_location/doc/requirements-doc.txt sphinx: configuration: modules/stock_product_location/doc/conf.py diff --git a/modules/stock_product_location/doc/conf.py b/modules/stock_product_location/doc/conf.py index 540e9c3069..160e673624 100644 --- a/modules/stock_product_location/doc/conf.py +++ b/modules/stock_product_location/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_product_location/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_product_location/doc/requirements-doc.txt b/modules/stock_product_location/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_product_location/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_quantity_early_planning/.readthedocs.yaml b/modules/stock_quantity_early_planning/.readthedocs.yaml index 61b38db048..41c4d4b020 100644 --- a/modules/stock_quantity_early_planning/.readthedocs.yaml +++ b/modules/stock_quantity_early_planning/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_quantity_early_planning/doc/requirements-doc.txt sphinx: configuration: modules/stock_quantity_early_planning/doc/conf.py diff --git a/modules/stock_quantity_early_planning/doc/conf.py b/modules/stock_quantity_early_planning/doc/conf.py index 540e9c3069..0251ac32b1 100644 --- a/modules/stock_quantity_early_planning/doc/conf.py +++ b/modules/stock_quantity_early_planning/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_quantity_early_planning/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_quantity_early_planning/doc/requirements-doc.txt b/modules/stock_quantity_early_planning/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_quantity_early_planning/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_quantity_issue/.readthedocs.yaml b/modules/stock_quantity_issue/.readthedocs.yaml index 664c5e0900..600ad5db19 100644 --- a/modules/stock_quantity_issue/.readthedocs.yaml +++ b/modules/stock_quantity_issue/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_quantity_issue/doc/requirements-doc.txt sphinx: configuration: modules/stock_quantity_issue/doc/conf.py diff --git a/modules/stock_quantity_issue/doc/conf.py b/modules/stock_quantity_issue/doc/conf.py index 540e9c3069..0230e14082 100644 --- a/modules/stock_quantity_issue/doc/conf.py +++ b/modules/stock_quantity_issue/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_quantity_issue/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_quantity_issue/doc/requirements-doc.txt b/modules/stock_quantity_issue/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_quantity_issue/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_secondary_unit/.readthedocs.yaml b/modules/stock_secondary_unit/.readthedocs.yaml index 60ad29efc4..4b8ab923c9 100644 --- a/modules/stock_secondary_unit/.readthedocs.yaml +++ b/modules/stock_secondary_unit/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_secondary_unit/doc/requirements-doc.txt sphinx: configuration: modules/stock_secondary_unit/doc/conf.py diff --git a/modules/stock_secondary_unit/doc/conf.py b/modules/stock_secondary_unit/doc/conf.py index 540e9c3069..337777aa3f 100644 --- a/modules/stock_secondary_unit/doc/conf.py +++ b/modules/stock_secondary_unit/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_secondary_unit/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_secondary_unit/doc/requirements-doc.txt b/modules/stock_secondary_unit/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_secondary_unit/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_shipment_cost/.readthedocs.yaml b/modules/stock_shipment_cost/.readthedocs.yaml index 213c7d60d0..55224e4d3d 100644 --- a/modules/stock_shipment_cost/.readthedocs.yaml +++ b/modules/stock_shipment_cost/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_shipment_cost/doc/requirements-doc.txt sphinx: configuration: modules/stock_shipment_cost/doc/conf.py diff --git a/modules/stock_shipment_cost/doc/conf.py b/modules/stock_shipment_cost/doc/conf.py index 540e9c3069..9615855bd2 100644 --- a/modules/stock_shipment_cost/doc/conf.py +++ b/modules/stock_shipment_cost/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_shipment_cost/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_shipment_cost/doc/requirements-doc.txt b/modules/stock_shipment_cost/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_shipment_cost/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_shipment_cost_weight/.readthedocs.yaml b/modules/stock_shipment_cost_weight/.readthedocs.yaml index e3de7302ea..674ef6d6a5 100644 --- a/modules/stock_shipment_cost_weight/.readthedocs.yaml +++ b/modules/stock_shipment_cost_weight/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_shipment_cost_weight/doc/requirements-doc.txt sphinx: configuration: modules/stock_shipment_cost_weight/doc/conf.py diff --git a/modules/stock_shipment_cost_weight/doc/conf.py b/modules/stock_shipment_cost_weight/doc/conf.py index 540e9c3069..b2cc0340fe 100644 --- a/modules/stock_shipment_cost_weight/doc/conf.py +++ b/modules/stock_shipment_cost_weight/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_shipment_cost_weight/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_shipment_cost_weight/doc/requirements-doc.txt b/modules/stock_shipment_cost_weight/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_shipment_cost_weight/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_shipment_measurements/.readthedocs.yaml b/modules/stock_shipment_measurements/.readthedocs.yaml index 1924446c56..840720e588 100644 --- a/modules/stock_shipment_measurements/.readthedocs.yaml +++ b/modules/stock_shipment_measurements/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_shipment_measurements/doc/requirements-doc.txt sphinx: configuration: modules/stock_shipment_measurements/doc/conf.py diff --git a/modules/stock_shipment_measurements/doc/conf.py b/modules/stock_shipment_measurements/doc/conf.py index 540e9c3069..3e2096c90e 100644 --- a/modules/stock_shipment_measurements/doc/conf.py +++ b/modules/stock_shipment_measurements/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_shipment_measurements/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_shipment_measurements/doc/requirements-doc.txt b/modules/stock_shipment_measurements/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_shipment_measurements/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_split/.readthedocs.yaml b/modules/stock_split/.readthedocs.yaml index 459bf6ea4b..bfd8b0c01e 100644 --- a/modules/stock_split/.readthedocs.yaml +++ b/modules/stock_split/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_split/doc/requirements-doc.txt sphinx: configuration: modules/stock_split/doc/conf.py diff --git a/modules/stock_split/doc/conf.py b/modules/stock_split/doc/conf.py index 540e9c3069..eee5883f60 100644 --- a/modules/stock_split/doc/conf.py +++ b/modules/stock_split/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_split/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_split/doc/requirements-doc.txt b/modules/stock_split/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_split/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_supply/.readthedocs.yaml b/modules/stock_supply/.readthedocs.yaml index 6324e333f2..62dd26cbc3 100644 --- a/modules/stock_supply/.readthedocs.yaml +++ b/modules/stock_supply/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_supply/doc/requirements-doc.txt sphinx: configuration: modules/stock_supply/doc/conf.py diff --git a/modules/stock_supply/doc/conf.py b/modules/stock_supply/doc/conf.py index 540e9c3069..61c5ec5ea5 100644 --- a/modules/stock_supply/doc/conf.py +++ b/modules/stock_supply/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_supply/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_supply/doc/requirements-doc.txt b/modules/stock_supply/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_supply/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_supply_day/.readthedocs.yaml b/modules/stock_supply_day/.readthedocs.yaml index 226c243228..5ab386d4cc 100644 --- a/modules/stock_supply_day/.readthedocs.yaml +++ b/modules/stock_supply_day/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_supply_day/doc/requirements-doc.txt sphinx: configuration: modules/stock_supply_day/doc/conf.py diff --git a/modules/stock_supply_day/doc/conf.py b/modules/stock_supply_day/doc/conf.py index 540e9c3069..e1ede01ce7 100644 --- a/modules/stock_supply_day/doc/conf.py +++ b/modules/stock_supply_day/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_supply_day/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_supply_day/doc/requirements-doc.txt b/modules/stock_supply_day/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_supply_day/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_supply_forecast/.readthedocs.yaml b/modules/stock_supply_forecast/.readthedocs.yaml index 77a4690062..081de51123 100644 --- a/modules/stock_supply_forecast/.readthedocs.yaml +++ b/modules/stock_supply_forecast/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_supply_forecast/doc/requirements-doc.txt sphinx: configuration: modules/stock_supply_forecast/doc/conf.py diff --git a/modules/stock_supply_forecast/doc/conf.py b/modules/stock_supply_forecast/doc/conf.py index 540e9c3069..b20c7e605d 100644 --- a/modules/stock_supply_forecast/doc/conf.py +++ b/modules/stock_supply_forecast/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_supply_forecast/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_supply_forecast/doc/requirements-doc.txt b/modules/stock_supply_forecast/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_supply_forecast/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/stock_supply_production/.readthedocs.yaml b/modules/stock_supply_production/.readthedocs.yaml index 2bd26d555f..f9732537c3 100644 --- a/modules/stock_supply_production/.readthedocs.yaml +++ b/modules/stock_supply_production/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_stock_supply_production/doc/requirements-doc.txt sphinx: configuration: modules/stock_supply_production/doc/conf.py diff --git a/modules/stock_supply_production/doc/conf.py b/modules/stock_supply_production/doc/conf.py index 540e9c3069..5abd82d3ac 100644 --- a/modules/stock_supply_production/doc/conf.py +++ b/modules/stock_supply_production/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/stock_supply_production/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/stock_supply_production/doc/requirements-doc.txt b/modules/stock_supply_production/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/stock_supply_production/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/timesheet/.readthedocs.yaml b/modules/timesheet/.readthedocs.yaml index 4a73e456a7..97042a85da 100644 --- a/modules/timesheet/.readthedocs.yaml +++ b/modules/timesheet/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_timesheet/doc/requirements-doc.txt sphinx: configuration: modules/timesheet/doc/conf.py diff --git a/modules/timesheet/doc/conf.py b/modules/timesheet/doc/conf.py index 540e9c3069..58bcafd142 100644 --- a/modules/timesheet/doc/conf.py +++ b/modules/timesheet/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/timesheet/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/timesheet/doc/requirements-doc.txt b/modules/timesheet/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/timesheet/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/timesheet_cost/.readthedocs.yaml b/modules/timesheet_cost/.readthedocs.yaml index 7a80ed1dbb..a38657896a 100644 --- a/modules/timesheet_cost/.readthedocs.yaml +++ b/modules/timesheet_cost/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_timesheet_cost/doc/requirements-doc.txt sphinx: configuration: modules/timesheet_cost/doc/conf.py diff --git a/modules/timesheet_cost/doc/conf.py b/modules/timesheet_cost/doc/conf.py index 540e9c3069..047ee68032 100644 --- a/modules/timesheet_cost/doc/conf.py +++ b/modules/timesheet_cost/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/timesheet_cost/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/timesheet_cost/doc/requirements-doc.txt b/modules/timesheet_cost/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/timesheet_cost/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/user_role/.readthedocs.yaml b/modules/user_role/.readthedocs.yaml index 4c9cfbc6bd..82e8aa60dc 100644 --- a/modules/user_role/.readthedocs.yaml +++ b/modules/user_role/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_user_role/doc/requirements-doc.txt sphinx: configuration: modules/user_role/doc/conf.py diff --git a/modules/user_role/doc/conf.py b/modules/user_role/doc/conf.py index 540e9c3069..4eb5576d06 100644 --- a/modules/user_role/doc/conf.py +++ b/modules/user_role/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/user_role/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/user_role/doc/requirements-doc.txt b/modules/user_role/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/user_role/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/web_shop/.readthedocs.yaml b/modules/web_shop/.readthedocs.yaml index 110271dada..75c84f365a 100644 --- a/modules/web_shop/.readthedocs.yaml +++ b/modules/web_shop/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_web_shop/doc/requirements-doc.txt sphinx: configuration: modules/web_shop/doc/conf.py diff --git a/modules/web_shop/doc/conf.py b/modules/web_shop/doc/conf.py index 540e9c3069..5dec7962a0 100644 --- a/modules/web_shop/doc/conf.py +++ b/modules/web_shop/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/web_shop/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/web_shop/doc/requirements-doc.txt b/modules/web_shop/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/web_shop/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/web_shop_shopify/.readthedocs.yaml b/modules/web_shop_shopify/.readthedocs.yaml index 84c3da7d2d..1b2053a463 100644 --- a/modules/web_shop_shopify/.readthedocs.yaml +++ b/modules/web_shop_shopify/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_web_shop_shopify/doc/requirements-doc.txt sphinx: configuration: modules/web_shop_shopify/doc/conf.py diff --git a/modules/web_shop_shopify/doc/conf.py b/modules/web_shop_shopify/doc/conf.py index 540e9c3069..81732cfd4c 100644 --- a/modules/web_shop_shopify/doc/conf.py +++ b/modules/web_shop_shopify/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/web_shop_shopify/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/web_shop_shopify/doc/requirements-doc.txt b/modules/web_shop_shopify/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/web_shop_shopify/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/web_shop_vue_storefront/.readthedocs.yaml b/modules/web_shop_vue_storefront/.readthedocs.yaml index ff669fb3aa..28818daa5f 100644 --- a/modules/web_shop_vue_storefront/.readthedocs.yaml +++ b/modules/web_shop_vue_storefront/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_web_shop_vue_storefront/doc/requirements-doc.txt sphinx: configuration: modules/web_shop_vue_storefront/doc/conf.py diff --git a/modules/web_shop_vue_storefront/doc/conf.py b/modules/web_shop_vue_storefront/doc/conf.py index 540e9c3069..43316befbb 100644 --- a/modules/web_shop_vue_storefront/doc/conf.py +++ b/modules/web_shop_vue_storefront/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/web_shop_vue_storefront/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/web_shop_vue_storefront/doc/requirements-doc.txt b/modules/web_shop_vue_storefront/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/web_shop_vue_storefront/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/web_shop_vue_storefront_stripe/.readthedocs.yaml b/modules/web_shop_vue_storefront_stripe/.readthedocs.yaml index c7d765c218..0bf343d318 100644 --- a/modules/web_shop_vue_storefront_stripe/.readthedocs.yaml +++ b/modules/web_shop_vue_storefront_stripe/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_web_shop_vue_storefront_stripe/doc/requirements-doc.txt sphinx: configuration: modules/web_shop_vue_storefront_stripe/doc/conf.py diff --git a/modules/web_shop_vue_storefront_stripe/doc/conf.py b/modules/web_shop_vue_storefront_stripe/doc/conf.py index 540e9c3069..f7fca24ea5 100644 --- a/modules/web_shop_vue_storefront_stripe/doc/conf.py +++ b/modules/web_shop_vue_storefront_stripe/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/web_shop_vue_storefront_stripe/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/web_shop_vue_storefront_stripe/doc/requirements-doc.txt b/modules/web_shop_vue_storefront_stripe/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/web_shop_vue_storefront_stripe/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/web_shortener/.readthedocs.yaml b/modules/web_shortener/.readthedocs.yaml index 185b9cc656..1b01e5426b 100644 --- a/modules/web_shortener/.readthedocs.yaml +++ b/modules/web_shortener/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_web_shortener/doc/requirements-doc.txt sphinx: configuration: modules/web_shortener/doc/conf.py diff --git a/modules/web_shortener/doc/conf.py b/modules/web_shortener/doc/conf.py index 540e9c3069..96c4481fcc 100644 --- a/modules/web_shortener/doc/conf.py +++ b/modules/web_shortener/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/web_shortener/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/web_shortener/doc/requirements-doc.txt b/modules/web_shortener/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/web_shortener/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/modules/web_user/.readthedocs.yaml b/modules/web_user/.readthedocs.yaml index 4c7770e846..79b0d88072 100644 --- a/modules/web_user/.readthedocs.yaml +++ b/modules/web_user/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: modules/trytond_web_user/doc/requirements-doc.txt sphinx: configuration: modules/web_user/doc/conf.py diff --git a/modules/web_user/doc/conf.py b/modules/web_user/doc/conf.py index 540e9c3069..ae2aa7dce6 100644 --- a/modules/web_user/doc/conf.py +++ b/modules/web_user/doc/conf.py @@ -25,9 +25,10 @@ def get_info(): info = dict(config.items('tryton')) result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -38,8 +39,10 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] for key in {'depends', 'extras_depend'}: info[key] = info.get(key, '').strip().splitlines() @@ -51,12 +54,25 @@ def get_info(): info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'modules/web_user/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/modules/web_user/doc/requirements-doc.txt b/modules/web_user/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/modules/web_user/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/proteus/.readthedocs.yaml b/proteus/.readthedocs.yaml index f50908c39a..7282d6cf1a 100644 --- a/proteus/.readthedocs.yaml +++ b/proteus/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: proteus/doc/requirements-doc.txt sphinx: configuration: proteus/doc/conf.py diff --git a/proteus/doc/conf.py b/proteus/doc/conf.py index 717d9fabc6..4cc7805e9e 100644 --- a/proteus/doc/conf.py +++ b/proteus/doc/conf.py @@ -22,9 +22,10 @@ def get_info(): info = dict() result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -35,20 +36,35 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] return info info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'proteus/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/proteus/doc/requirements-doc.txt b/proteus/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/proteus/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/readthedocs/.readthedocs.yaml b/readthedocs/.readthedocs.yaml index 2d55475253..9e4076dd03 100644 --- a/readthedocs/.readthedocs.yaml +++ b/readthedocs/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: readthedocs/requirements-doc.txt sphinx: configuration: readthedocs/conf.py diff --git a/readthedocs/conf.py b/readthedocs/conf.py index 9d44983dd4..33cac6a01e 100644 --- a/readthedocs/conf.py +++ b/readthedocs/conf.py @@ -1,8 +1,23 @@ # This file is part of Tryton. The COPYRIGHT file at the top level of # this repository contains the full copyright notices and license terms. +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': 'branch/default', + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'readthedocs', + } +html_title = "Tryton Documentation" master_doc = 'index' project = "Tryton Documentation" default_role = 'ref' highlight_language = 'none' +extensions = [ + 'sphinx_copybutton', + ] linkcheck_ignore = [r'/.*', r'https://demo.tryton.org/*'] diff --git a/readthedocs/requirements-doc.txt b/readthedocs/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/readthedocs/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/tryton/.readthedocs.yaml b/tryton/.readthedocs.yaml index 569cc9086f..ebb5cc5b63 100644 --- a/tryton/.readthedocs.yaml +++ b/tryton/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: tryton/doc/requirements-doc.txt sphinx: configuration: tryton/doc/conf.py diff --git a/tryton/doc/conf.py b/tryton/doc/conf.py index 717d9fabc6..2104c4631d 100644 --- a/tryton/doc/conf.py +++ b/tryton/doc/conf.py @@ -22,9 +22,10 @@ def get_info(): info = dict() result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -35,20 +36,35 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] return info info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'tryton/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/tryton/doc/requirements-doc.txt b/tryton/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/tryton/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/trytond-gis/.readthedocs.yaml b/trytond-gis/.readthedocs.yaml index 5784d55890..3b1e2b4dce 100644 --- a/trytond-gis/.readthedocs.yaml +++ b/trytond-gis/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: trytond-gis/doc/requirements-doc.txt sphinx: configuration: trytond-gis/doc/conf.py diff --git a/trytond-gis/doc/conf.py b/trytond-gis/doc/conf.py index 94a6aa4f3a..5e79128d39 100644 --- a/trytond-gis/doc/conf.py +++ b/trytond-gis/doc/conf.py @@ -22,9 +22,10 @@ def get_info(): info = dict() result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -35,20 +36,35 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] return info info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'trytond-gis/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/trytond-gis/doc/requirements-doc.txt b/trytond-gis/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/trytond-gis/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton diff --git a/trytond/.readthedocs.yaml b/trytond/.readthedocs.yaml index b9b5ce1a9c..1be2e53476 100644 --- a/trytond/.readthedocs.yaml +++ b/trytond/.readthedocs.yaml @@ -3,5 +3,8 @@ build: os: ubuntu-22.04 tools: python: "3" +python: + install: + - requirements: trytond/doc/requirements-doc.txt sphinx: configuration: trytond/doc/conf.py diff --git a/trytond/doc/conf.py b/trytond/doc/conf.py index 717d9fabc6..e74b0f6809 100644 --- a/trytond/doc/conf.py +++ b/trytond/doc/conf.py @@ -22,9 +22,10 @@ def get_info(): info = dict() result = subprocess.run( - [sys.executable, 'setup.py', '--name'], + [sys.executable, 'setup.py', '--name', '--description'], stdout=subprocess.PIPE, check=True, cwd=module_dir) - info['name'] = result.stdout.decode('utf-8').strip() + info['name'], info['description'] = ( + result.stdout.decode('utf-8').strip().splitlines()) result = subprocess.run( [sys.executable, 'setup.py', '--version'], @@ -35,20 +36,35 @@ def get_info(): minor_version = int(minor_version) if minor_version % 2: info['series'] = 'latest' + info['branch'] = 'branch/default' else: info['series'] = '.'.join(version.split('.', 2)[:2]) + info['branch'] = 'branch/' + info['series'] return info info = get_info() +html_theme = 'sphinx_book_theme' +html_theme_options = { + 'repository_provider': 'gitlab', + 'repository_url': 'https://code.tryton.org/tryton', + 'repository_branch': info['branch'], + 'use_source_button': True, + 'use_edit_page_button': True, + 'use_repository_button': True, + 'use_download_button': False, + 'path_to_docs': 'trytond/doc', + } +html_title = info['description'] master_doc = 'index' project = info['name'] release = version = info['series'] default_role = 'ref' highlight_language = 'none' extensions = [ + 'sphinx_copybutton', 'sphinx.ext.intersphinx', ] intersphinx_mapping = { diff --git a/trytond/doc/index.rst b/trytond/doc/index.rst index 89930ac9be..24a34f2471 100644 --- a/trytond/doc/index.rst +++ b/trytond/doc/index.rst @@ -60,10 +60,3 @@ Contents modules/index tutorial/index releases - -Indices, glossary and tables -============================ - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/trytond/doc/requirements-doc.txt b/trytond/doc/requirements-doc.txt new file mode 100644 index 0000000000..fee3b273bd --- /dev/null +++ b/trytond/doc/requirements-doc.txt @@ -0,0 +1,2 @@ +sphinx_book_theme +sphinx_copybutton