Skip to content

Commit ce1110c

Browse files
committed
wip: use sphinxdocs for docgen
1 parent 8337731 commit ce1110c

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+1200
-976
lines changed

.bazelci/presubmit.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,14 @@ tasks:
1212
- "--enable_workspace"
1313
test_targets:
1414
- "..."
15-
all_tests_workspace_5.x:
16-
name: Workspace (Bazel 5.x)
15+
all_tests_workspace_minimum_bazel:
16+
name: Workspace (Bazel 6.x)
1717
platform: ${{platform}}
1818
skip_in_bazel_downstream_pipeline: Already tested on latest
19-
bazel: "5.x"
19+
bazel: "6.x"
2020
test_flags:
21-
- "--noexperimental_enable_bzlmod"
21+
- "--noenable_bzlmod"
22+
- "--test_tag_filters=-docs"
2223
test_targets:
2324
- "..."
2425
all_tests_bzlmod:
@@ -38,7 +39,6 @@ tasks:
3839
test_flags:
3940
- "--enable_bzlmod"
4041
test_targets:
41-
- "//docgen/..."
4242
- "//docs/..."
4343

4444
e2e_bzlmod:

.gitignore

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +0,0 @@
1-
# Generated sphinx docs
2-
docs/_build/
3-
# Generated API docs
4-
/docs/source/api/
5-
!/docs/source/api/index.md

.readthedocs.yaml

Lines changed: 7 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,14 @@
11

22
version: 2
33

4-
formats:
5-
- pdf
6-
- htmlzip
7-
8-
sphinx:
9-
configuration: docs/source/conf.py
10-
114
build:
125
os: "ubuntu-22.04"
136
tools:
14-
python: "3.11"
157
nodejs: "19"
16-
jobs:
17-
pre_build:
18-
- npm install -g @bazel/bazelisk
19-
- bazel run //docs:run_sphinx_build
20-
21-
python:
22-
install:
23-
- requirements: docs/requirements.txt
8+
commands:
9+
- env
10+
- npm install -g @bazel/bazelisk
11+
- bazel version
12+
# Put the actual action behind a shell script because it's
13+
# easier to modify than the yaml config.
14+
- docs/readthedocs_build.sh

MODULE.bazel

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ module(
44
compatibility_level = 1,
55
)
66

7+
bazel_dep(name = "rules_python", version = "0.37.0")
78
bazel_dep(name = "platforms", version = "0.0.6")
89
bazel_dep(name = "bazel_skylib", version = "1.3.0")
910
bazel_dep(name = "rules_license", version = "0.0.4")
@@ -18,7 +19,6 @@ bazel_dep(
1819
dev_dependency = True,
1920
repo_name = "io_bazel_stardoc",
2021
)
21-
bazel_dep(name = "rules_python", version = "0.27.0", dev_dependency = True)
2222

2323
python = use_extension(
2424
"@rules_python//python/extensions:python.bzl",
@@ -40,3 +40,8 @@ pip.parse(
4040
requirements_lock = "//docs:requirements.txt",
4141
)
4242
use_repo(pip, "docs-pypi")
43+
44+
##local_path_override(
45+
## module_name = "rules_python",
46+
## path = "../rules_python",
47+
##)

MODULE.bazel.lock

Lines changed: 161 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

WORKSPACE.bazel

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,17 @@ http_archive(
3131
],
3232
)
3333

34+
http_archive(
35+
name = "rules_python",
36+
sha256 = "0cc05ddb27614baecace068986931e2a6e9f69114e6115fc5dc58250faf56e0f",
37+
strip_prefix = "rules_python-0.37.0",
38+
url = "https://github.com/bazelbuild/rules_python/releases/download/0.37.0/rules_python-0.37.0.tar.gz",
39+
)
40+
41+
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
42+
43+
py_repositories()
44+
3445
load("@io_bazel_stardoc//:setup.bzl", "stardoc_repositories")
3546

3647
stardoc_repositories()
@@ -52,15 +63,6 @@ http_archive(
5263
],
5364
)
5465

55-
http_archive(
56-
name = "rules_python",
57-
sha256 = "a644da969b6824cc87f8fe7b18101a8a6c57da5db39caa6566ec6109f37d2141",
58-
strip_prefix = "rules_python-0.20.0",
59-
url = "https://github.com/bazelbuild/rules_python/releases/download/0.20.0/rules_python-0.20.0.tar.gz",
60-
)
61-
62-
load("@rules_python//python:repositories.bzl", "python_register_toolchains")
63-
6466
python_register_toolchains(
6567
name = "python3_11",
6668
# Available versions are listed in @rules_python//python:versions.bzl.

docgen/BUILD

Lines changed: 0 additions & 51 deletions
This file was deleted.

0 commit comments

Comments
 (0)