summaryrefslogtreecommitdiffstats
path: root/documentation/Makefile
diff options
context:
space:
mode:
authorMichael Opdenacker <michael.opdenacker@bootlin.com>2024-03-12 21:58:39 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2024-03-19 15:22:27 +0000
commite987c5151c34cb388cc1a106a21bdc118206cfac (patch)
tree9f121a698078e93094e3dcb0995f94a7912c4dc7 /documentation/Makefile
parent08081135175e26efb868653d7c9cfd6089576326 (diff)
downloadpoky-e987c5151c34cb388cc1a106a21bdc118206cfac.tar.gz
manuals: add initial stylechecks with Vale
Use the "Vale" (https://vale.sh) tool to perform text style checks Run "make stylecheck" to run the checks. This just checks the text, not the Sphinx syntax style choices. (From yocto-docs rev: d145e1dc45dc0792c8b8f7e73500b56face1e710) Signed-off-by: Michael Opdenacker <michael.opdenacker@bootlin.com> Suggested-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'documentation/Makefile')
-rw-r--r--documentation/Makefile9
1 files changed, 8 insertions, 1 deletions
diff --git a/documentation/Makefile b/documentation/Makefile
index 9fb6814c8f..60268e955c 100644
--- a/documentation/Makefile
+++ b/documentation/Makefile
@@ -5,6 +5,9 @@
5# from the environment for the first two. 5# from the environment for the first two.
6SPHINXOPTS ?= -W --keep-going -j auto 6SPHINXOPTS ?= -W --keep-going -j auto
7SPHINXBUILD ?= sphinx-build 7SPHINXBUILD ?= sphinx-build
8# Release notes are excluded because they contain contributor names and commit messages which can't be modified
9VALEOPTS ?= --no-wrap --glob '!migration-guides/release-notes-*.rst'
10VALEDOCS ?= .
8SOURCEDIR = . 11SOURCEDIR = .
9IMAGEDIRS = */svg 12IMAGEDIRS = */svg
10BUILDDIR = _build 13BUILDDIR = _build
@@ -20,7 +23,7 @@ endif
20help: 23help:
21 @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) 24 @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
22 25
23.PHONY: all help Makefile clean publish epub latexpdf 26.PHONY: all help Makefile clean stylecheck publish epub latexpdf
24 27
25publish: Makefile html singlehtml 28publish: Makefile html singlehtml
26 rm -rf $(BUILDDIR)/$(DESTDIR)/ 29 rm -rf $(BUILDDIR)/$(DESTDIR)/
@@ -46,6 +49,10 @@ PNGs := $(foreach dir, $(IMAGEDIRS), $(patsubst %.svg,%.png,$(wildcard $(SOURCED
46clean: 49clean:
47 @rm -rf $(BUILDDIR) $(PNGs) $(PDFs) poky.yaml sphinx-static/switchers.js 50 @rm -rf $(BUILDDIR) $(PNGs) $(PDFs) poky.yaml sphinx-static/switchers.js
48 51
52stylecheck:
53 vale sync
54 vale $(VALEOPTS) $(VALEDOCS)
55
49epub: $(PNGs) 56epub: $(PNGs)
50 $(SOURCEDIR)/set_versions.py 57 $(SOURCEDIR)/set_versions.py
51 @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) 58 @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)