From 2f12e89148a4e1592870dfb0c0a4d1d3a11918a6 Mon Sep 17 00:00:00 2001 From: Anne Chew Date: Wed, 24 Jun 2026 21:04:59 +0800 Subject: [PATCH] feature: add sphinx-unified-search Signed-off-by: Anne Chew --- docs/conf.py | 17 +++++++++++++++++ docs/requirements.txt | 4 +++- 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/docs/conf.py b/docs/conf.py index dfc624e..618c23c 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -306,6 +306,7 @@ "sphinx_sitemap", "sphinx_rerediraffe", "sphinx_llm.txt", + "sphinx_unified_search", ] # Excludes files or directories from processing @@ -375,3 +376,19 @@ if "discourse_prefix" not in html_context and "discourse" in html_context: html_context["discourse_prefix"] = html_context["discourse"] + "/t/" + +# sphinx-unified-search configuration +unified_search_projects = [ + { + "name": "Landscape", + "base_url": "https://ubuntu.com/landscape/docs", + "searchindex_url": + "https://ubuntu.com/landscape/docs/searchindex.js", + }, + { + "name": "Pebble", + "base_url": "https://ubuntu.com/docs/pebble/", + "searchindex_url": + "https://ubuntu.com/docs/pebble/searchindex.js", + }, +] diff --git a/docs/requirements.txt b/docs/requirements.txt index 69c0782..ffcc296 100644 --- a/docs/requirements.txt +++ b/docs/requirements.txt @@ -31,4 +31,6 @@ sphinx-llm~=0.4 # Vale dependencies rst2html -vale~=3.13 \ No newline at end of file +vale==3.13.0.0 + +git+https://github.com/canonical/sphinx-unified-search.git@main