mirror of
https://github.com/pybricks/pybricks-api.git
synced 2026-09-11 17:14:41 +00:00
doc/common/conf: Default to main on RTD.
It would be nicer to specify this in the .readthedocs.yaml file, but this appears to not to be supported.
This commit is contained in:
@@ -42,6 +42,10 @@ from pybricks._common import Speaker # noqa E402
|
||||
# this line of code grabbed from docs.readthedocs.org
|
||||
ON_RTD = os.environ.get('READTHEDOCS', None) == 'True'
|
||||
|
||||
# Since tags cannot be passed via SPHINXOPTS on read the docs, add it manually.
|
||||
if ON_RTD:
|
||||
tags.add('main')
|
||||
|
||||
_pyproject = toml.load(os.path.join(TOP_DIR, 'pyproject.toml'))
|
||||
|
||||
# -- General configuration ------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user