annotate Makefile @ 268:ea19b621081d

Consistently write code blocks in the documentation text as "code block". Previously it sometimes was "code-block".
author Franz Glasner <fzglas.hg@dom66.de>
date Tue, 19 May 2026 21:11:28 +0200
parents b27557f6d393
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
15
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
1 # dev and build helper
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
2 # :-
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
3 # SPDX-FileCopyrightText: © 2026 Franz Glasner
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
4 # SPDX-License-Identifier: MIT
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
5 # :-
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
6
178
0eec7988fdc0 Make targets: "docs" -> "doc"
Franz Glasner <fzglas.hg@dom66.de>
parents: 177
diff changeset
7 .PHONY: help all clean distclean dist export build tests flake8 doc clean-doc doc-html clean-doc-html doc-pdf clean-doc-pdf install-dev install-doc
15
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
8
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
9 help:
178
0eec7988fdc0 Make targets: "docs" -> "doc"
Franz Glasner <fzglas.hg@dom66.de>
parents: 177
diff changeset
10 @echo Targets: help, clean, distclean, export, dist, build, tests, doc clean-doc
15
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
11
16
b92f660f2461 Begin a test infrastructure: using unittest and flake8.
Franz Glasner <fzglas.hg@dom66.de>
parents: 15
diff changeset
12 all: tests flake8
b92f660f2461 Begin a test infrastructure: using unittest and flake8.
Franz Glasner <fzglas.hg@dom66.de>
parents: 15
diff changeset
13
15
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
14 build:
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
15 python -m build
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
16
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
17 dist: distclean build
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
18
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
19 distclean: clean
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
20 rm -rf dist/ *.egg-info
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
21
167
ddefcc20367c More static and/or dynamic metadata into README and project's init: release date, revision.
Franz Glasner <fzglas.hg@dom66.de>
parents: 45
diff changeset
22 export:
ddefcc20367c More static and/or dynamic metadata into README and project's init: release date, revision.
Franz Glasner <fzglas.hg@dom66.de>
parents: 45
diff changeset
23 rm -rf __arch
ddefcc20367c More static and/or dynamic metadata into README and project's init: release date, revision.
Franz Glasner <fzglas.hg@dom66.de>
parents: 45
diff changeset
24 hg kwarchive __arch
ddefcc20367c More static and/or dynamic metadata into README and project's init: release date, revision.
Franz Glasner <fzglas.hg@dom66.de>
parents: 45
diff changeset
25
15
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
26 clean:
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
27 rm -rf __arch/
db0171f62e5a A Makefile to help building and testing
Franz Glasner <fzglas.hg@dom66.de>
parents:
diff changeset
28 find . -name '*.pyc' -delete
16
b92f660f2461 Begin a test infrastructure: using unittest and flake8.
Franz Glasner <fzglas.hg@dom66.de>
parents: 15
diff changeset
29
b92f660f2461 Begin a test infrastructure: using unittest and flake8.
Franz Glasner <fzglas.hg@dom66.de>
parents: 15
diff changeset
30 tests:
b92f660f2461 Begin a test infrastructure: using unittest and flake8.
Franz Glasner <fzglas.hg@dom66.de>
parents: 15
diff changeset
31 -python -m unittest discover -s tests
b92f660f2461 Begin a test infrastructure: using unittest and flake8.
Franz Glasner <fzglas.hg@dom66.de>
parents: 15
diff changeset
32
b92f660f2461 Begin a test infrastructure: using unittest and flake8.
Franz Glasner <fzglas.hg@dom66.de>
parents: 15
diff changeset
33 flake8:
b92f660f2461 Begin a test infrastructure: using unittest and flake8.
Franz Glasner <fzglas.hg@dom66.de>
parents: 15
diff changeset
34 -flake8 pygments_lexer_pseudocode2
b92f660f2461 Begin a test infrastructure: using unittest and flake8.
Franz Glasner <fzglas.hg@dom66.de>
parents: 15
diff changeset
35 -flake8 tests
44
742496328de6 Add an "install-dev" target
Franz Glasner <fzglas.hg@dom66.de>
parents: 16
diff changeset
36
178
0eec7988fdc0 Make targets: "docs" -> "doc"
Franz Glasner <fzglas.hg@dom66.de>
parents: 177
diff changeset
37 doc: doc-html doc-pdf
45
6ac1ea5d2d4a Begin documentation: add the Sphinx generated configuration as-is
Franz Glasner <fzglas.hg@dom66.de>
parents: 44
diff changeset
38
178
0eec7988fdc0 Make targets: "docs" -> "doc"
Franz Glasner <fzglas.hg@dom66.de>
parents: 177
diff changeset
39 clean-doc:
45
6ac1ea5d2d4a Begin documentation: add the Sphinx generated configuration as-is
Franz Glasner <fzglas.hg@dom66.de>
parents: 44
diff changeset
40 (cd docs && make clean)
6ac1ea5d2d4a Begin documentation: add the Sphinx generated configuration as-is
Franz Glasner <fzglas.hg@dom66.de>
parents: 44
diff changeset
41
178
0eec7988fdc0 Make targets: "docs" -> "doc"
Franz Glasner <fzglas.hg@dom66.de>
parents: 177
diff changeset
42 doc-html:
177
b291f1e2319d Refactor make targets because of PDF generation
Franz Glasner <fzglas.hg@dom66.de>
parents: 171
diff changeset
43 (cd docs && make html)
b291f1e2319d Refactor make targets because of PDF generation
Franz Glasner <fzglas.hg@dom66.de>
parents: 171
diff changeset
44
178
0eec7988fdc0 Make targets: "docs" -> "doc"
Franz Glasner <fzglas.hg@dom66.de>
parents: 177
diff changeset
45 clean-doc-html:
45
6ac1ea5d2d4a Begin documentation: add the Sphinx generated configuration as-is
Franz Glasner <fzglas.hg@dom66.de>
parents: 44
diff changeset
46 rm -rf docs/_build/html
6ac1ea5d2d4a Begin documentation: add the Sphinx generated configuration as-is
Franz Glasner <fzglas.hg@dom66.de>
parents: 44
diff changeset
47
178
0eec7988fdc0 Make targets: "docs" -> "doc"
Franz Glasner <fzglas.hg@dom66.de>
parents: 177
diff changeset
48 doc-pdf:
171
4b87a9ecffdd The first somewhat useable version of documentation in PDF.
Franz Glasner <fzglas.hg@dom66.de>
parents: 167
diff changeset
49 (cd docs && make latex)
4b87a9ecffdd The first somewhat useable version of documentation in PDF.
Franz Glasner <fzglas.hg@dom66.de>
parents: 167
diff changeset
50 (cd docs/_build/latex && gmake)
4b87a9ecffdd The first somewhat useable version of documentation in PDF.
Franz Glasner <fzglas.hg@dom66.de>
parents: 167
diff changeset
51
178
0eec7988fdc0 Make targets: "docs" -> "doc"
Franz Glasner <fzglas.hg@dom66.de>
parents: 177
diff changeset
52 clean-doc-pdf:
171
4b87a9ecffdd The first somewhat useable version of documentation in PDF.
Franz Glasner <fzglas.hg@dom66.de>
parents: 167
diff changeset
53 rm -rf docs/_build/latex
4b87a9ecffdd The first somewhat useable version of documentation in PDF.
Franz Glasner <fzglas.hg@dom66.de>
parents: 167
diff changeset
54
44
742496328de6 Add an "install-dev" target
Franz Glasner <fzglas.hg@dom66.de>
parents: 16
diff changeset
55 install-dev:
742496328de6 Add an "install-dev" target
Franz Glasner <fzglas.hg@dom66.de>
parents: 16
diff changeset
56 python -m pip install -r requirements-dev.txt
45
6ac1ea5d2d4a Begin documentation: add the Sphinx generated configuration as-is
Franz Glasner <fzglas.hg@dom66.de>
parents: 44
diff changeset
57
178
0eec7988fdc0 Make targets: "docs" -> "doc"
Franz Glasner <fzglas.hg@dom66.de>
parents: 177
diff changeset
58 install-doc:
45
6ac1ea5d2d4a Begin documentation: add the Sphinx generated configuration as-is
Franz Glasner <fzglas.hg@dom66.de>
parents: 44
diff changeset
59 python -m pip install -r requirements-docs.txt
185
b27557f6d393 Allow to build the documentation when the project is not installed
Franz Glasner <fzglas.hg@dom66.de>
parents: 178
diff changeset
60 # Not needed any more because handled in docs/conf.py as hack
b27557f6d393 Allow to build the documentation when the project is not installed
Franz Glasner <fzglas.hg@dom66.de>
parents: 178
diff changeset
61 #python -m pip install --editable .