From e45279964d439a352eac2360aa7f7a7bf0cbf950 Mon Sep 17 00:00:00 2001 From: Tibor Leupold Date: Tue, 5 Apr 2022 15:11:56 -0700 Subject: [PATCH 1/5] Add serve command to make --- Makefile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Makefile b/Makefile index 1c1a2e73..67b03c6a 100644 --- a/Makefile +++ b/Makefile @@ -109,6 +109,11 @@ docs: ## Regenerate Sphinx HTML documentation, including API docs $(MAKE) -C docs html +.PHONY: serve +serve: ## Serve docs at http://localhost:8000 + python -m http.server --directory ./docs/_build/html + + .PHONY: frontend frontend: ## Compile frontend files npm run frontend From ac6b0ca804a95caf2a3600b25ba38d9d85f00bb4 Mon Sep 17 00:00:00 2001 From: Tibor Leupold Date: Tue, 5 Apr 2022 15:16:14 -0700 Subject: [PATCH 2/5] Update getting started instruction in README --- README.md | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 5a2291a0..c2e4ab94 100644 --- a/README.md +++ b/README.md @@ -39,8 +39,13 @@ html_theme = 'sphinx_wagtail_theme' - Clone this repo locally - Set up a Python virtual environment (e.g. `venv`) - Show all available tasks via `make` -- Run `make setup` and then `make docs` to install and build the docs locally -- See the documentation for more development instructions +- Run `make setup` to install the dependencies +- Run `make frontend` to build the frontend assets +- Run `make install-for-dev` to build the theme package and install it in editable mode +- Run `make docs` to build the theme docs, which also serve as the example docs to develop the theme +- Run `make serve` to serve the theme at http://localhost:8000 + +See the documentation for more development instructions. ### Release process From dfeb2f9dad3d1afa59ae0dd52ed33c95da0f04c4 Mon Sep 17 00:00:00 2001 From: Tibor Leupold Date: Tue, 5 Apr 2022 15:18:02 -0700 Subject: [PATCH 3/5] Update instructions in docs/development The `make docs` command did not have the effect of serving the docs and opening the browser anymore. Not sure why. But I have updated the docs accordingly and mention the command to maually start serving the docs. --- docs/development.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/development.rst b/docs/development.rst index f01d3173..94807f70 100644 --- a/docs/development.rst +++ b/docs/development.rst @@ -29,13 +29,13 @@ Build and install the package:: make install -Don't forget to update the docs. Render the documentation and show in browser:: +Don't forget to update the docs. Render the documentation:: make docs -Without opening the browser:: +Serve build docs locally:: - non_interactive=1 make docs + make serve Check the Python code. The CI workflow requires `lint-minimal` to succeed:: From 7ff4dba6f7a4416608b0c9b058aae272a66bdc8d Mon Sep 17 00:00:00 2001 From: Tibor Leupold Date: Tue, 5 Apr 2022 15:21:49 -0700 Subject: [PATCH 4/5] Fix sentence --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index c2e4ab94..004644ad 100644 --- a/README.md +++ b/README.md @@ -43,7 +43,7 @@ html_theme = 'sphinx_wagtail_theme' - Run `make frontend` to build the frontend assets - Run `make install-for-dev` to build the theme package and install it in editable mode - Run `make docs` to build the theme docs, which also serve as the example docs to develop the theme -- Run `make serve` to serve the theme at http://localhost:8000 +- Run `make serve` to serve the theme docs at http://localhost:8000 See the documentation for more development instructions. From c5152ce3bd6a2a6f213ee37d4450b6836c803084 Mon Sep 17 00:00:00 2001 From: Tibor Leupold Date: Tue, 5 Apr 2022 17:25:39 -0700 Subject: [PATCH 5/5] Remove outdated reference to typo3 theme stress test --- docs/development.rst | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) diff --git a/docs/development.rst b/docs/development.rst index 94807f70..6576afa1 100644 --- a/docs/development.rst +++ b/docs/development.rst @@ -66,19 +66,13 @@ can be uploaded to PyPi run:: .. _venv: https://docs.python.org/3/library/venv.html -Theme stress test -================= - -There is a demo manual `t3SphinxThemeRtdDemoDocs`_ -under construction. It serves as a "stress test" for this `sphinx_wagtail_theme`_ -and tries to use as many reStructuredText examples as possible and covered by -the theme. **Documentation writers** may want to have a look at those pages to -understand what reST markup can be used and what the visual effect will be. -**Theme contributors** should use the demo manual for testing and *visually* -check the rendering. - -.. _t3SphinxThemeRtdDemoDocs: https://docs.typo3.org/m/typo3/demo-t3SphinxThemeRtd/master/en-us/ -.. _sphinx_wagtail_theme: https://github.com/typo3-documentation/sphinx_wagtail_theme +Example pages +============= + +When working on the theme it is often going to be helpful to know the impact of your changes. +The :doc:`examples section ` should be helpful for this. + +When you are adding new elements or styles that are not part of the examples, please make sure to add them. Javascript package management