Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ benchmarks/ @rapidsai/rmm-cpp-codeowners
#python code owners
python/ @rapidsai/rmm-python-codeowners

#docs code owners
fern/ @rapidsai/rmm-cpp-codeowners @rapidsai/rmm-python-codeowners

#cmake code owners
**/CMakeLists.txt @rapidsai/rmm-cmake-codeowners
**/cmake/ @rapidsai/rmm-cmake-codeowners
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ jobs:
- '!ci/test_wheel.sh'
- '!ci/validate_wheel.sh'
- '!docs/**'
- '!fern/**'
- '!img/**'
- '!python/**'
test_python_conda:
Expand Down Expand Up @@ -165,6 +166,7 @@ jobs:
- '!cpp/.clang-tidy'
- '!cpp/doxygen/**'
- '!docs/**'
- '!fern/**'
- '!img/**'
test_python_wheels:
- '**'
Expand Down Expand Up @@ -197,6 +199,7 @@ jobs:
- '!cpp/.clang-tidy'
- '!cpp/doxygen/**'
- '!docs/**'
- '!fern/**'
- '!img/**'
checks:
permissions:
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,8 @@ cpp/doxygen/html
cpp/doxygen/latex
cpp/doxygen/xml
docs/_build
fern/pages/api_reference
fern/sphinx/build

#Java
target
Expand Down Expand Up @@ -134,6 +136,7 @@ celerybeat-schedule

# dotenv
.env
.venv-docs/

# virtualenv
.venv
Expand Down
10 changes: 8 additions & 2 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,12 @@ ARGS=$*
# script, and that this script resides in the repo dir!
REPODIR=$(cd "$(dirname "$0")"; pwd)

VALIDARGS="clean librmm rmm -v -g -n --ptds -h tests benchmarks"
HELP="$0 [clean] [librmm] [rmm] [-v] [-g] [-n] [--ptds] [--cmake-args=\"<args>\"] [-h]
VALIDARGS="clean librmm rmm docs -v -g -n --ptds -h tests benchmarks"
HELP="$0 [clean] [librmm] [rmm] [docs] [-v] [-g] [-n] [--ptds] [--cmake-args=\"<args>\"] [-h]
clean - remove all existing build artifacts and configuration (start over)
librmm - build and install the librmm C++ code
rmm - build and install the rmm Python package
docs - validate the Fern documentation
benchmarks - build benchmarks
tests - build tests
-v - verbose build mode
Expand Down Expand Up @@ -183,3 +184,8 @@ if (( NUMARGS == 0 )) || hasArg rmm; then
"${PYTHON_ARGS_FOR_INSTALL[@]}" \
"${REPODIR}"/python/rmm
fi

# Validate Fern docs
if hasArg docs; then
"${REPODIR}/fern/build_docs.sh" "${FERN_DOCS_MODE:-check}"
fi
32 changes: 3 additions & 29 deletions ci/build_docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,49 +4,23 @@

set -euo pipefail

rapids-logger "Downloading artifacts from previous jobs"
CPP_CHANNEL=$(rapids-download-conda-from-github cpp)
PYTHON_CHANNEL=$(rapids-download-from-github "$(rapids-package-name "conda_python" rmm --stable --cuda "$RAPIDS_CUDA_VERSION")")

rapids-logger "Create test conda environment"
rapids-logger "Create docs conda environment"

. /opt/conda/etc/profile.d/conda.sh

rapids-logger "Configuring conda strict channel priority"
conda config --set channel_priority strict

RAPIDS_VERSION_MAJOR_MINOR="$(rapids-version-major-minor)"
export RAPIDS_VERSION_MAJOR_MINOR

rapids-dependency-file-generator \
--output conda \
--file-key docs \
--matrix "cuda=${RAPIDS_CUDA_VERSION%.*};arch=$(arch);py=${RAPIDS_PY_VERSION}" \
--prepend-channel "${CPP_CHANNEL}" \
--prepend-channel "${PYTHON_CHANNEL}" \
| tee env.yaml

rapids-mamba-retry env create --yes -f env.yaml -n docs
conda activate docs

rapids-print-env

RAPIDS_DOCS_DIR="$(mktemp -d)"
export RAPIDS_DOCS_DIR


rapids-logger "Build CPP docs"
pushd cpp/doxygen
doxygen Doxyfile
mkdir -p "${RAPIDS_DOCS_DIR}/librmm/html"
mv html/* "${RAPIDS_DOCS_DIR}/librmm/html"
popd

rapids-logger "Build Python docs"
pushd docs
make dirhtml
mkdir -p "${RAPIDS_DOCS_DIR}/rmm/html"
mv _build/dirhtml/* "${RAPIDS_DOCS_DIR}/rmm/html"
popd

RAPIDS_VERSION_NUMBER="${RAPIDS_VERSION_MAJOR_MINOR}" rapids-upload-docs
rapids-logger "Validate Fern docs"
fern/build_docs.sh "${FERN_DOCS_MODE:-check}"
7 changes: 2 additions & 5 deletions conda/environments/all_cuda-129_arch-aarch64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,9 @@ dependencies:
- gcovr>=5.0
- graphviz
- identify>=2.5.20
- ipython
- make
- myst-parser
- nbsphinx
- ninja
- nodejs>=18
- numba-cuda>=0.22.1,<0.29.0
- numba>=0.60.0,<0.65.0
- numpy>=1.23,<3.0
Expand All @@ -39,8 +37,7 @@ dependencies:
- rapids-logger==0.2.*,>=0.0.0a0
- scikit-build-core>=0.11.0
- sphinx
- sphinx-copybutton
- sphinx-markdown-builder
- sphinx-markdown-tables
- sphinxcontrib-jquery
- sysroot_linux-aarch64==2.28
name: all_cuda-129_arch-aarch64
7 changes: 2 additions & 5 deletions conda/environments/all_cuda-129_arch-x86_64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,9 @@ dependencies:
- gcovr>=5.0
- graphviz
- identify>=2.5.20
- ipython
- make
- myst-parser
- nbsphinx
- ninja
- nodejs>=18
- numba-cuda>=0.22.1,<0.29.0
- numba>=0.60.0,<0.65.0
- numpy>=1.23,<3.0
Expand All @@ -39,8 +37,7 @@ dependencies:
- rapids-logger==0.2.*,>=0.0.0a0
- scikit-build-core>=0.11.0
- sphinx
- sphinx-copybutton
- sphinx-markdown-builder
- sphinx-markdown-tables
- sphinxcontrib-jquery
- sysroot_linux-64==2.28
name: all_cuda-129_arch-x86_64
7 changes: 2 additions & 5 deletions conda/environments/all_cuda-132_arch-aarch64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,9 @@ dependencies:
- gcovr>=5.0
- graphviz
- identify>=2.5.20
- ipython
- make
- myst-parser
- nbsphinx
- ninja
- nodejs>=18
- numba-cuda>=0.22.1,<0.29.0
- numba>=0.60.0,<0.65.0
- numpy>=1.23,<3.0
Expand All @@ -39,8 +37,7 @@ dependencies:
- rapids-logger==0.2.*,>=0.0.0a0
- scikit-build-core>=0.11.0
- sphinx
- sphinx-copybutton
- sphinx-markdown-builder
- sphinx-markdown-tables
- sphinxcontrib-jquery
- sysroot_linux-aarch64==2.28
name: all_cuda-132_arch-aarch64
7 changes: 2 additions & 5 deletions conda/environments/all_cuda-132_arch-x86_64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,9 @@ dependencies:
- gcovr>=5.0
- graphviz
- identify>=2.5.20
- ipython
- make
- myst-parser
- nbsphinx
- ninja
- nodejs>=18
- numba-cuda>=0.22.1,<0.29.0
- numba>=0.60.0,<0.65.0
- numpy>=1.23,<3.0
Expand All @@ -39,8 +37,7 @@ dependencies:
- rapids-logger==0.2.*,>=0.0.0a0
- scikit-build-core>=0.11.0
- sphinx
- sphinx-copybutton
- sphinx-markdown-builder
- sphinx-markdown-tables
- sphinxcontrib-jquery
- sysroot_linux-64==2.28
name: all_cuda-132_arch-x86_64
18 changes: 9 additions & 9 deletions dependencies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,9 @@ files:
includes:
- cuda_version
- docs
- py_version
- depends_on_rmm
- depends_on_librmm
- depends_on_rmm
- py_version
py_cpp_build:
output: pyproject
pyproject_dir: python/librmm
Expand Down Expand Up @@ -336,18 +336,16 @@ dependencies:
- breathe>=4.35.0
- *doxygen
- graphviz
- ipython
- make
- myst-parser
- nbsphinx
- &numba numba>=0.60.0,<0.65.0
- &numba_cuda numba-cuda>=0.22.1,<0.29.0
- nodejs>=18
- numba>=0.60.0,<0.65.0
- numba-cuda>=0.22.1,<0.29.0
- numpydoc
- packaging
- pydata-sphinx-theme>=0.15.4
- sphinx
- sphinx-copybutton
- sphinx-markdown-builder
- sphinx-markdown-tables
- sphinxcontrib-jquery
py_version:
specific:
- output_types: conda
Expand Down Expand Up @@ -395,6 +393,8 @@ dependencies:
common:
- output_types: [conda, requirements, pyproject]
packages:
- &numba numba>=0.60.0,<0.65.0
- &numba_cuda numba-cuda>=0.22.1,<0.29.0
- packaging
- pytest
- pytest-cov
Expand Down
23 changes: 0 additions & 23 deletions docs/Makefile

This file was deleted.

Binary file removed docs/_static/RAPIDS-logo-purple.png
Binary file not shown.
105 changes: 105 additions & 0 deletions fern/build_docs.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
#!/bin/bash
# SPDX-FileCopyrightText: Copyright (c) 2026, NVIDIA CORPORATION.
# SPDX-License-Identifier: Apache-2.0

set -euo pipefail

SCRIPT_DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
REPO_DIR=$(cd "${SCRIPT_DIR}/.." && pwd)
MODE="${1:-check}"

if [[ $# -gt 0 ]]; then
shift
fi

usage() {
cat <<'EOF'
Usage: fern/build_docs.sh [check|preview|publish|dev] [fern arguments...]

Modes:
check Validate Fern configuration, links, and Markdown syntax.
preview Build and publish a Fern preview deployment.
publish Build and publish the production Fern docs site.
dev Start Fern's local docs preview server.
EOF
}

require_node_18() {
if ! command -v node >/dev/null 2>&1; then
echo "Fern docs require Node.js 18 or newer, but node was not found on PATH." >&2
exit 1
fi

local node_version
local node_major
node_version=$(node -p 'process.versions.node' 2>/dev/null || true)
node_major="${node_version%%.*}"

if [[ ! "${node_major}" =~ ^[0-9]+$ || "${node_major}" -lt 18 ]]; then
echo "Fern docs require Node.js 18 or newer, but found Node.js ${node_version:-unknown}." >&2
exit 1
fi
}

require_node_18

if [[ -n "${FERN_CLI:-}" ]]; then
FERN_CMD=("${FERN_CLI}")
elif command -v fern >/dev/null 2>&1; then
FERN_CMD=("fern")
else
FERN_CMD=("npx" "--yes" "fern-api@5.30.4")
fi
Comment thread
coderabbitai[bot] marked this conversation as resolved.

run_fern() {
"${FERN_CMD[@]}" "$@"
}

generate_api_reference() {
pushd "${REPO_DIR}" >/dev/null
python3 fern/scripts/generate_api_reference.py
popd >/dev/null
}

run_checks() {
pushd "${REPO_DIR}" >/dev/null
run_fern check --warnings
run_fern docs md check
popd >/dev/null
}

case "${MODE}" in
check)
generate_api_reference
run_checks
;;
preview)
generate_api_reference
run_checks
pushd "${REPO_DIR}" >/dev/null
run_fern generate --docs --preview "$@"
popd >/dev/null
;;
publish)
generate_api_reference
run_checks
pushd "${REPO_DIR}" >/dev/null
run_fern generate --docs "$@"
popd >/dev/null
;;
dev)
generate_api_reference
pushd "${REPO_DIR}" >/dev/null
run_fern docs dev "$@"
popd >/dev/null
;;
-h|--help|help)
usage
;;
*)
echo "Unknown mode: ${MODE}" >&2
echo >&2
usage >&2
exit 2
;;
esac
Loading
Loading