Skip to content

Commit fe23d35

Browse files
daipomlidavidm
andauthored
docs: organize Documentation steps of CONTRIBUTING.md (#3100)
Closes #3080 Co-authored-by: David Li <li.davidm96@gmail.com>
1 parent 6e0a9e5 commit fe23d35

File tree

1 file changed

+37
-12
lines changed

1 file changed

+37
-12
lines changed

CONTRIBUTING.md

Lines changed: 37 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -220,33 +220,58 @@ $ npm install -g @mermaid-js/mermaid-cli
220220
To build the HTML documentation:
221221

222222
```shell
223-
$ pushd c/apidoc
224-
$ doxygen
225-
$ popd
226-
227-
# Optionally: to also build the Python documentation
228-
$ pushd python/adbc_driver_manager
229-
$ pip install -e .[test]
230-
$ popd
231-
232223
$ pushd docs
233224
$ make html
234225
```
235226

236-
The output can be found in `build/`.
227+
The output can be found in `build/`. This does not generate API references
228+
and results in some warnings, but it is not a problem if you're not working
229+
with the API documentation.
237230

238231
Some documentations are maintained as [Mermaid][mermaid] diagrams, which must
239232
be rendered and checked in. This can be done as follows:
240233

241234
```shell
242-
pushd docs
243-
make -f mermaid.makefile -j all
235+
$ pushd docs
236+
$ make -f mermaid.makefile -j all
244237
# Check in the updated files
245238
```
246239

247240
[mermaid]: https://mermaid.js.org/
248241
[sphinx]: https://www.sphinx-doc.org/en/master/
249242

243+
#### Building more complete documentation
244+
245+
You can remove the warnings of `make html` and generate the Python API
246+
reference as follows:
247+
248+
```shell
249+
$ mamba create -n adbc \
250+
--file ci/conda_env_docs.txt \
251+
--file ci/conda_env_cpp.txt \
252+
--file ci/conda_env_python.txt \
253+
--file ci/conda_env_java.txt
254+
$ mamba activate adbc
255+
$ env ADBC_USE_ASAN=0 ADBC_USE_UBSAN=0 ./ci/scripts/python_build.sh $(pwd) $(pwd)/build
256+
$ pushd docs
257+
$ make html
258+
```
259+
260+
For a more complete build, you can use the following script:
261+
262+
```shell
263+
$ ./ci/scripts/docs_build.sh "$(pwd)"
264+
```
265+
266+
This generates all available API references, and also runs doctests.
267+
268+
To generate the R API reference, you need to run the following additionally:
269+
270+
```shell
271+
$ mamba install --file ci/conda_env_r.txt
272+
$ ./ci/scripts/r_build.sh $(pwd)
273+
```
274+
250275
### GLib
251276

252277
The GLib bindings use the [Meson][meson] build system.

0 commit comments

Comments
 (0)