From ea7fe1fc2775fe996972011545e90c3aaac876cc Mon Sep 17 00:00:00 2001 From: Alexander Lanin Date: Tue, 11 Nov 2025 13:10:11 +0100 Subject: [PATCH 1/5] wip --- .bazelrc | 6 ++++++ .github/workflows/docs.yml | 42 ++++++++++++++++++++++++++++++++++++++ .gitignore | 6 +++++- BUILD | 16 ++++++++------- docs/conf.py | 26 +++++++++++++++++++++++ docs/index.rst | 27 ++++++++++++++++++++++++ docs/requirements.txt | 1 - score_modules.MODULE.bazel | 20 ++++++++++++++---- 8 files changed, 131 insertions(+), 13 deletions(-) create mode 100644 .github/workflows/docs.yml create mode 100644 docs/conf.py create mode 100644 docs/index.rst delete mode 100644 docs/requirements.txt diff --git a/.bazelrc b/.bazelrc index fd22d465ac..000f8b456c 100644 --- a/.bazelrc +++ b/.bazelrc @@ -56,3 +56,9 @@ test --sandbox_tmpfs_path=/tmp # user specific overrides (like proxy settings) try-import %workspace%/user.bazelrc + +# Java +build --java_language_version=17 +build --tool_java_language_version=17 +build --java_runtime_version=remotejdk_17 +build --tool_java_runtime_version=remotejdk_17 diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml new file mode 100644 index 0000000000..fa0420bcac --- /dev/null +++ b/.github/workflows/docs.yml @@ -0,0 +1,42 @@ +# ******************************************************************************* +# Copyright (c) 2025 Contributors to the Eclipse Foundation +# +# See the NOTICE file(s) distributed with this work for additional +# information regarding copyright ownership. +# +# This program and the accompanying materials are made available under the +# terms of the Apache License Version 2.0 which is available at +# https://www.apache.org/licenses/LICENSE-2.0 +# +# SPDX-License-Identifier: Apache-2.0 +# ******************************************************************************* + +name: Documentation + +permissions: + contents: write + pages: write + pull-requests: write + id-token: write + +on: + pull_request_target: # Allows forks to trigger the docs build + types: [opened, reopened, synchronize] + push: + branches: + - main + merge_group: + types: [checks_requested] + +jobs: + build-docs: + uses: eclipse-score/cicd-workflows/.github/workflows/docs.yml@main + permissions: + contents: write + pages: write + pull-requests: write + id-token: write + + with: + bazel-target: "//:docs_combo_experimental -- --github_user=${{ github.repository_owner }} --github_repo=${{ github.event.repository.name }}" + retention-days: 3 diff --git a/.gitignore b/.gitignore index db54c5cd2d..26b5e28ab0 100644 --- a/.gitignore +++ b/.gitignore @@ -16,4 +16,8 @@ rust-project.json __pycache__/ .pytest_cache/ /.coverage -**/*.egg-info/* \ No newline at end of file +**/*.egg-info/* + +# Docs +/_build +/docs/ubproject.toml diff --git a/BUILD b/BUILD index 83cf914f6b..c99f0286a5 100644 --- a/BUILD +++ b/BUILD @@ -11,14 +11,16 @@ # SPDX-License-Identifier: Apache-2.0 # ******************************************************************************* -# load("@score_docs_as_code//:docs.bzl", "docs") +load("@score_docs_as_code//:docs.bzl", "docs") -# docs( -# data = [ -# # TODO: add all modules that have docs -# ], -# source_dir = "docs", -# ) +docs( + data = [ + "@score_platform//:needs_json", + "@score_process//:needs_json", + "@score_persistency//:needs_json", + ], + source_dir = "docs", +) # Simple filegroup target to demonstrate the build system works filegroup( diff --git a/docs/conf.py b/docs/conf.py new file mode 100644 index 0000000000..f4e526ffc1 --- /dev/null +++ b/docs/conf.py @@ -0,0 +1,26 @@ +# ******************************************************************************* +# Copyright (c) 2025 Contributors to the Eclipse Foundation +# +# See the NOTICE file(s) distributed with this work for additional +# information regarding copyright ownership. +# +# This program and the accompanying materials are made available under the +# terms of the Apache License Version 2.0 which is available at +# https://www.apache.org/licenses/LICENSE-2.0 +# +# SPDX-License-Identifier: Apache-2.0 +# ******************************************************************************* + +# Configuration file for the Sphinx documentation builder. + +project = "REF_INT" +project_url = "https://eclipse-score.github.io/reference_integration" +version = "0.1" + +extensions = [ + # TODO: remove plantuml here once + # https://github.com/useblocks/sphinx-needs/pull/1508 is merged and docs-as-code + # is updated with new sphinx-needs version + "sphinxcontrib.plantuml", + "score_sphinx_bundle", +] diff --git a/docs/index.rst b/docs/index.rst new file mode 100644 index 0000000000..5e5f327f40 --- /dev/null +++ b/docs/index.rst @@ -0,0 +1,27 @@ +.. + # ******************************************************************************* + # Copyright (c) 2025 Contributors to the Eclipse Foundation + # + # See the NOTICE file(s) distributed with this work for additional + # information regarding copyright ownership. + # + # This program and the accompanying materials are made available under the + # terms of the Apache License Version 2.0 which is available at + # https://www.apache.org/licenses/LICENSE-2.0 + # + # SPDX-License-Identifier: Apache-2.0 + # ******************************************************************************* + +Reference Integration Documentation +=================================== + +Included Modules: + +.. if-collection:: score_platform + .. toctree:: + :maxdepth: 2 + :titlesonly: + + _collections/score_process/process/index + _collections/score_platform/docs/index + _collections/score_persistency/docs/index diff --git a/docs/requirements.txt b/docs/requirements.txt deleted file mode 100644 index fdffa2a0fd..0000000000 --- a/docs/requirements.txt +++ /dev/null @@ -1 +0,0 @@ -# placeholder diff --git a/score_modules.MODULE.bazel b/score_modules.MODULE.bazel index 4c9714ca2d..df1ee2ae43 100644 --- a/score_modules.MODULE.bazel +++ b/score_modules.MODULE.bazel @@ -24,10 +24,9 @@ single_version_override( ) bazel_dep(name = "score_persistency") -git_override( +local_path_override( module_name = "score_persistency", - remote = "https://github.com/eclipse-score/persistency.git", - commit = "393c1c30e6959ff5befe85751baee8a8cd8024e9", # Nov 7, 2025, 7:37 AM GMT+1 + path = "../persistency", ) bazel_dep(name = "score_orchestrator") @@ -45,7 +44,7 @@ single_version_override( bazel_dep(name = "score_platform") single_version_override( module_name = "score_platform", - version = "0.3.0", + version = "0.4.1", ) bazel_dep(name = "score_bazel_platforms") @@ -59,3 +58,16 @@ single_version_override( module_name = "score_test_scenarios", version = "0.3.0", ) + +bazel_dep(name = "score_docs_as_code", version = "2.0.1") +single_version_override( + module_name = "score_docs_as_code", + version = "2.0.1", +) + + +bazel_dep(name = "score_process", version = "1.3.1") +single_version_override( + module_name = "score_process", + version = "1.3.1", +) From a73ba324e33e590bfc880bc89af8759fa5a8a1df Mon Sep 17 00:00:00 2001 From: Alexander Lanin Date: Tue, 11 Nov 2025 15:34:03 +0100 Subject: [PATCH 2/5] skip persistency docs --- BUILD | 4 +++- docs/index.rst | 12 ++++++------ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/BUILD b/BUILD index c99f0286a5..8ef451a21e 100644 --- a/BUILD +++ b/BUILD @@ -17,7 +17,9 @@ docs( data = [ "@score_platform//:needs_json", "@score_process//:needs_json", - "@score_persistency//:needs_json", + # Persistency cannot be included, as it does not contain any needs. + # -> sphinx-needs bug? + # "@score_persistency//:needs_json", ], source_dir = "docs", ) diff --git a/docs/index.rst b/docs/index.rst index 5e5f327f40..6dd15078c6 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -18,10 +18,10 @@ Reference Integration Documentation Included Modules: .. if-collection:: score_platform - .. toctree:: - :maxdepth: 2 - :titlesonly: - _collections/score_process/process/index - _collections/score_platform/docs/index - _collections/score_persistency/docs/index + .. toctree:: + :maxdepth: 2 + :titlesonly: + + _collections/score_process/process/index + _collections/score_platform/docs/index From c08d65a2f72e26582137a9a59a14596cd376b07a Mon Sep 17 00:00:00 2001 From: Alexander Lanin Date: Tue, 11 Nov 2025 15:53:50 +0100 Subject: [PATCH 3/5] set score_persistency to 0.2.1 --- score_modules.MODULE.bazel | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/score_modules.MODULE.bazel b/score_modules.MODULE.bazel index df1ee2ae43..022d8dec85 100644 --- a/score_modules.MODULE.bazel +++ b/score_modules.MODULE.bazel @@ -24,9 +24,9 @@ single_version_override( ) bazel_dep(name = "score_persistency") -local_path_override( +single_version_override( module_name = "score_persistency", - path = "../persistency", + version = "0.2.1", ) bazel_dep(name = "score_orchestrator") From 3a3f47158240e2b95af981b6da8e3b0049ebaedb Mon Sep 17 00:00:00 2001 From: Alexander Lanin Date: Tue, 11 Nov 2025 16:09:23 +0100 Subject: [PATCH 4/5] final fixes --- README.md | 6 ++++++ docs/index.rst | 8 ++++---- score_modules.MODULE.bazel | 9 +++++++-- 3 files changed, 17 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index d13ec9851b..ca07fd6ef2 100644 --- a/README.md +++ b/README.md @@ -10,6 +10,12 @@ The reference integration workspace serves as a single Bazel build environment t - Test toolchain and platform support (Linux, QNX, LLVM/GCC) - Prepare for release validation workflows +## Docs + +To generate a full documentation of all integrated modules, run: +```bash +bazel run //:docs_combo_experimental +``` ## Working Builds ✅ The following modules build successfully with the `bl-x86_64-linux` configuration: diff --git a/docs/index.rst b/docs/index.rst index 6dd15078c6..9cafe3cde2 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -15,13 +15,13 @@ Reference Integration Documentation =================================== -Included Modules: - .. if-collection:: score_platform + Included S-CORE Modules: + .. toctree:: - :maxdepth: 2 + :maxdepth: 1 :titlesonly: + S-CORE Platform <_collections/score_platform/docs/index> _collections/score_process/process/index - _collections/score_platform/docs/index diff --git a/score_modules.MODULE.bazel b/score_modules.MODULE.bazel index 022d8dec85..67e2b95075 100644 --- a/score_modules.MODULE.bazel +++ b/score_modules.MODULE.bazel @@ -42,9 +42,14 @@ single_version_override( ) bazel_dep(name = "score_platform") -single_version_override( +# single_version_override( +# module_name = "score_platform", +# version = "0.4.1", +# ) +git_override( module_name = "score_platform", - version = "0.4.1", + remote = "https://github.com/eclipse-score/score.git", + commit = "a9cf44be1342f3c62111de2249eb3132f5ab88da" # version 0.4.1 + fixes *from main branch* ) bazel_dep(name = "score_bazel_platforms") From 729523d382d740cd2e52b65d039bedf44ed4aa81 Mon Sep 17 00:00:00 2001 From: Alexander Lanin Date: Tue, 11 Nov 2025 17:16:56 +0100 Subject: [PATCH 5/5] review findings --- .bazelrc | 6 +++--- MODULE.bazel | 2 +- score_modules.MODULE.bazel | 3 ++- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/.bazelrc b/.bazelrc index 000f8b456c..1b19025099 100644 --- a/.bazelrc +++ b/.bazelrc @@ -54,11 +54,11 @@ test:bl-x86_64-linux --test_output=errors test --sandbox_tmpfs_path=/dev/shm test --sandbox_tmpfs_path=/tmp -# user specific overrides (like proxy settings) -try-import %workspace%/user.bazelrc - # Java build --java_language_version=17 build --tool_java_language_version=17 build --java_runtime_version=remotejdk_17 build --tool_java_runtime_version=remotejdk_17 + +# user specific overrides (like proxy settings) +try-import %workspace%/user.bazelrc diff --git a/MODULE.bazel b/MODULE.bazel index a3e396b541..a09fca0c1a 100644 --- a/MODULE.bazel +++ b/MODULE.bazel @@ -13,7 +13,7 @@ module( name = "score_reference_integration", - version = "0.0.0", + version = "0.5.0-alpha.1", compatibility_level = 0, ) diff --git a/score_modules.MODULE.bazel b/score_modules.MODULE.bazel index 67e2b95075..62cb9f493a 100644 --- a/score_modules.MODULE.bazel +++ b/score_modules.MODULE.bazel @@ -42,9 +42,10 @@ single_version_override( ) bazel_dep(name = "score_platform") +# TODO: switch to 0.4.2 once released # single_version_override( # module_name = "score_platform", -# version = "0.4.1", +# version = "0.4.2", # ) git_override( module_name = "score_platform",