Skip to content

Commit

Permalink
Merge pull request #10 from OpenDataServices/2024-09-27
Browse files Browse the repository at this point in the history
docs: Switch to ODSC theme & config
  • Loading branch information
odscjames authored Sep 27, 2024
2 parents 5f35baa + 4fd78e6 commit bf90717
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 11 deletions.
11 changes: 7 additions & 4 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ version: 2

# Set the version of Python and other tools you might need
build:
os: ubuntu-22.04
os: ubuntu-24.04
tools:
python: "3.9"

Expand All @@ -17,6 +17,9 @@ sphinx:

# We recommend specifying your dependencies to enable reproducible builds:
# https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
# python:
# install:
# - requirements: docs/requirements.txt
python:
install:
- method: pip
path: .
extra_requirements:
- dev
2 changes: 2 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
project = "LibCoveWeb2"

master_doc = "index"

html_theme = "odsc_default_sphinx_theme"
12 changes: 6 additions & 6 deletions libcoveweb2/templatetags/cove_tags.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ def cove_modal_list(**kw):
@register.inclusion_tag("modal_errors.html")
def cove_modal_errors(**context):
if hasattr(settings, "VALIDATION_ERROR_LOCATIONS_LENGTH"):
context[
"validation_error_locations_length"
] = settings.VALIDATION_ERROR_LOCATIONS_LENGTH
context["validation_error_locations_length"] = (
settings.VALIDATION_ERROR_LOCATIONS_LENGTH
)
else:
context["validation_error_locations_length"] = 1000
if hasattr(settings, "VALIDATION_ERROR_LOCATIONS_SAMPLE"):
context[
"validation_error_locations_sample"
] = settings.VALIDATION_ERROR_LOCATIONS_SAMPLE
context["validation_error_locations_sample"] = (
settings.VALIDATION_ERROR_LOCATIONS_SAMPLE
)
return context


Expand Down
9 changes: 8 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,13 @@
"celery[redis]",
],
extras_require={
"dev": ["black", "isort", "flake8", "mypy"],
"dev": [
"black",
"isort",
"flake8",
"mypy",
"sphinx",
"odsc-default-sphinx-theme",
],
},
)

0 comments on commit bf90717

Please sign in to comment.