uEdition 0.8.0__tar.gz → 1.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of uEdition might be problematic. Click here for more details.
- uedition-1.0.0/.github/workflows/codestyle.yml +21 -0
- {uedition-0.8.0 → uedition-1.0.0}/.github/workflows/coverage.yml +4 -2
- {uedition-0.8.0 → uedition-1.0.0}/.github/workflows/tests.yml +1 -1
- {uedition-0.8.0 → uedition-1.0.0}/.gitignore +2 -1
- uedition-1.0.0/.pre-commit-config.yaml +10 -0
- {uedition-0.8.0 → uedition-1.0.0}/PKG-INFO +16 -6
- {uedition-0.8.0 → uedition-1.0.0}/README.md +11 -1
- uedition-1.0.0/docs/.readthedocs.yml +16 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/.uEdition.answers +3 -3
- uedition-1.0.0/docs/de/changelog.md +72 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/de/index.md +1 -1
- {uedition-0.8.0/docs/en → uedition-1.0.0/docs/de}/user/content.md +8 -9
- uedition-1.0.0/docs/de/user/create.md +15 -0
- uedition-1.0.0/docs/de/user/index.md +8 -0
- uedition-1.0.0/docs/de/user/installation.md +37 -0
- uedition-1.0.0/docs/de/user/language-add.md +14 -0
- uedition-1.0.0/docs/en/changelog.md +72 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/en/index.md +1 -1
- {uedition-0.8.0 → uedition-1.0.0}/docs/en/user/create.md +1 -1
- {uedition-0.8.0/docs/de → uedition-1.0.0/docs/en}/user/installation.md +1 -1
- uedition-1.0.0/docs/pyproject.toml +27 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/toc.yml +1 -0
- uedition-1.0.0/pyproject.toml +156 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/conftest.py +6 -5
- {uedition-0.8.0 → uedition-1.0.0}/tests/test_about.py +1 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/test_build.py +1 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/test_check.py +4 -9
- uedition-1.0.0/tests/test_ext/test_config.py +27 -0
- uedition-1.0.0/uedition/CHANGELOG.md +75 -0
- {uedition-0.8.0 → uedition-1.0.0}/uedition/__about__.py +1 -1
- {uedition-0.8.0 → uedition-1.0.0}/uedition/__init__.py +3 -3
- {uedition-0.8.0 → uedition-1.0.0}/uedition/__main__.py +1 -2
- {uedition-0.8.0 → uedition-1.0.0}/uedition/cli/__init__.py +8 -12
- {uedition-0.8.0 → uedition-1.0.0}/uedition/cli/build.py +72 -31
- {uedition-0.8.0 → uedition-1.0.0}/uedition/cli/check.py +24 -44
- {uedition-0.8.0 → uedition-1.0.0}/uedition/cli/language.py +4 -10
- {uedition-0.8.0 → uedition-1.0.0}/uedition/cli/serve.py +7 -8
- {uedition-0.8.0 → uedition-1.0.0}/uedition/cli/update.py +1 -1
- {uedition-0.8.0 → uedition-1.0.0}/uedition/ext/__init__.py +1 -1
- {uedition-0.8.0 → uedition-1.0.0}/uedition/ext/config.py +33 -52
- {uedition-0.8.0 → uedition-1.0.0}/uedition/ext/language_switcher.js +3 -3
- {uedition-0.8.0 → uedition-1.0.0}/uedition/ext/language_switcher.py +8 -9
- uedition-1.0.0/uedition/ext/tei/__init__.py +32 -0
- uedition-1.0.0/uedition/ext/tei/builder.py +297 -0
- uedition-0.8.0/uedition/ext/tei.py → uedition-1.0.0/uedition/ext/tei/parser.py +17 -35
- uedition-1.0.0/uedition/ext/tei/tei_download.js +34 -0
- {uedition-0.8.0 → uedition-1.0.0}/uedition/settings.py +28 -30
- uedition-0.8.0/.github/workflows/codestyle.yml +0 -16
- uedition-0.8.0/.pre-commit-config.yaml +0 -10
- uedition-0.8.0/.vscode/settings.json +0 -3
- uedition-0.8.0/docs/de/user/create.md +0 -13
- uedition-0.8.0/docs/en/user/index.md +0 -7
- uedition-0.8.0/docs/en/user/installation.md +0 -37
- uedition-0.8.0/docs/en/user/language-add.md +0 -14
- uedition-0.8.0/docs/pyproject.toml +0 -34
- uedition-0.8.0/pyproject.toml +0 -70
- uedition-0.8.0/tests/test_settings.py +0 -15
- {uedition-0.8.0 → uedition-1.0.0}/.github/dependabot.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/.github/workflows/release.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/.readthedocs.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/LICENSE.txt +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/.gitignore +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/de/.uEdition.answers +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/de/user/configuration.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/de/user/language-update.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/de/user/publish.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/de/user/update.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/en/.uEdition.answers +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/en/user/configuration.md +0 -0
- {uedition-0.8.0/docs/de → uedition-1.0.0/docs/en}/user/content.md +0 -0
- {uedition-0.8.0/docs/de → uedition-1.0.0/docs/en}/user/index.md +0 -0
- {uedition-0.8.0/docs/de → uedition-1.0.0/docs/en}/user/language-add.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/en/user/language-update.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/en/user/publish.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/en/user/update.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/docs/uEdition.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/__init__.py +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/basic/uEdition.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/empty/.gitkeep +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/invalid_core_files/en/_config.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/invalid_core_files/en/_toc.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/invalid_core_files/uEdition.yaml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_core_files/uEdition.yaml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_files/.gitignore +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_files/en/_config.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_files/en/_toc.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_files/en/intro.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_files/references.bib +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_files/uEdition.yaml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_toc_root/en/_config.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_toc_root/en/_toc.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_toc_root/uEdition.yaml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_toc_root_file/en/_config.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_toc_root_file/en/_toc.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/missing_toc_root_file/uEdition.yaml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/.gitignore +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/de/_config.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/de/_toc.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/de/a-1-page.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/de/a-2-page.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/de/a-page.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/de/b-page.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/de/intro.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/en/_config.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/en/_toc.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/en/a-1-page.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/en/a-2-page.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/en/a-page.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/en/b-page.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/en/intro.md +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/references.bib +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/toc.yml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/multilang/uEdition.yaml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tests/fixtures/yaml/uEdition.yaml +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/tox.ini +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/uedition/cli/create.py +0 -0
- {uedition-0.8.0 → uedition-1.0.0}/uedition/ext/language_switcher.css +0 -0
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
name: Code Style
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [ main ]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [ main ]
|
|
8
|
+
|
|
9
|
+
jobs:
|
|
10
|
+
black:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
|
|
13
|
+
steps:
|
|
14
|
+
- uses: actions/checkout@v4
|
|
15
|
+
- uses: psf/black@stable
|
|
16
|
+
|
|
17
|
+
ruff:
|
|
18
|
+
runs-on: ubuntu-latest
|
|
19
|
+
steps:
|
|
20
|
+
- uses: actions/checkout@v4
|
|
21
|
+
- uses: chartboost/ruff-action@v1
|
|
@@ -3,6 +3,8 @@ name: Coverage
|
|
|
3
3
|
on:
|
|
4
4
|
push:
|
|
5
5
|
branches: [ main ]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [ main ]
|
|
6
8
|
|
|
7
9
|
jobs:
|
|
8
10
|
coverage:
|
|
@@ -30,11 +32,11 @@ jobs:
|
|
|
30
32
|
|
|
31
33
|
- name: Run Tests
|
|
32
34
|
run: |
|
|
33
|
-
hatch run
|
|
35
|
+
hatch run cov
|
|
34
36
|
|
|
35
37
|
- name: Calculate coverage
|
|
36
38
|
run: |
|
|
37
|
-
hatch run
|
|
39
|
+
hatch run coverage json
|
|
38
40
|
export TOTAL=$(python -c "import json;print(json.load(open('coverage.json'))['totals']['percent_covered_display'])")
|
|
39
41
|
echo "total=$TOTAL" >> $GITHUB_ENV
|
|
40
42
|
echo "### Total coverage: ${TOTAL}%" >> $GITHUB_STEP_SUMMARY
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: uEdition
|
|
3
|
-
Version: 0.
|
|
4
|
-
Project-URL: Documentation, https://github.com/
|
|
5
|
-
Project-URL: Issues, https://github.com/
|
|
6
|
-
Project-URL: Source, https://github.com/
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Project-URL: Documentation, https://github.com/uEdition/uEdition#readme
|
|
5
|
+
Project-URL: Issues, https://github.com/uEdition/uEdition/issues
|
|
6
|
+
Project-URL: Source, https://github.com/uEdition/uEdition
|
|
7
7
|
Author-email: Mark Hall <mark.hall@work.room3b.eu>
|
|
8
8
|
License-Expression: MIT
|
|
9
9
|
License-File: LICENSE.txt
|
|
@@ -15,7 +15,7 @@ Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
|
15
15
|
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
|
16
16
|
Requires-Python: >=3.10
|
|
17
17
|
Requires-Dist: copier<10.0.0,>=9.0.0
|
|
18
|
-
Requires-Dist: jupyter-book<
|
|
18
|
+
Requires-Dist: jupyter-book<2.0.0,>=1.0.0
|
|
19
19
|
Requires-Dist: livereload
|
|
20
20
|
Requires-Dist: lxml<6.0.0,>=4.9.2
|
|
21
21
|
Requires-Dist: pydantic-settings<3.0.0,>=2.0.0
|
|
@@ -48,6 +48,16 @@ The recommended installation for use is via `pipx`:
|
|
|
48
48
|
pipx install uedition
|
|
49
49
|
```
|
|
50
50
|
|
|
51
|
+
All commands can then be run via
|
|
52
|
+
|
|
53
|
+
```console
|
|
54
|
+
uEdition {command}
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
## Documentation
|
|
58
|
+
|
|
59
|
+
Full documentation is available at [https://uedition.readthedocs.io](https://uedition.readthedocs.io).
|
|
60
|
+
|
|
51
61
|
## License
|
|
52
62
|
|
|
53
|
-
|
|
63
|
+
The μEdition is distributed under the terms of the [MIT](https://spdx.org/licenses/MIT.html) license.
|
|
@@ -22,6 +22,16 @@ The recommended installation for use is via `pipx`:
|
|
|
22
22
|
pipx install uedition
|
|
23
23
|
```
|
|
24
24
|
|
|
25
|
+
All commands can then be run via
|
|
26
|
+
|
|
27
|
+
```console
|
|
28
|
+
uEdition {command}
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
## Documentation
|
|
32
|
+
|
|
33
|
+
Full documentation is available at [https://uedition.readthedocs.io](https://uedition.readthedocs.io).
|
|
34
|
+
|
|
25
35
|
## License
|
|
26
36
|
|
|
27
|
-
|
|
37
|
+
The μEdition is distributed under the terms of the [MIT](https://spdx.org/licenses/MIT.html) license.
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
version: 2
|
|
2
|
+
|
|
3
|
+
build:
|
|
4
|
+
os: ubuntu-22.04
|
|
5
|
+
tools:
|
|
6
|
+
python: "3.11"
|
|
7
|
+
commands:
|
|
8
|
+
- "pip install hatch"
|
|
9
|
+
- "hatch run build"
|
|
10
|
+
- "mkdir $READTHEDOCS_OUTPUT"
|
|
11
|
+
- "mv site $READTHEDOCS_OUTPUT/html"
|
|
12
|
+
|
|
13
|
+
python:
|
|
14
|
+
install:
|
|
15
|
+
- method: pip
|
|
16
|
+
path: .
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# Changes here will be overwritten by Copier
|
|
2
|
-
_commit: v0.
|
|
3
|
-
_src_path:
|
|
2
|
+
_commit: v0.1.8
|
|
3
|
+
_src_path: gh:uEdition/uEdition-project-template
|
|
4
4
|
author_email: mark.hall@work.room3b.eu
|
|
5
5
|
author_name: Mark Hall
|
|
6
6
|
edition_name: μEdition
|
|
7
|
-
publishing:
|
|
7
|
+
publishing: readthedocs
|
|
8
8
|
repository_branch: main
|
|
9
9
|
repository_url: https://github.com/uEdition/uEdition
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
# Änderungsgeschichte
|
|
2
|
+
|
|
3
|
+
## 1.0.0 (31.01.2024)
|
|
4
|
+
|
|
5
|
+
* **Neu**: TEI Output ist optional
|
|
6
|
+
* **Aktualisiert**: JupyterBook auf Version 1 aktualisert
|
|
7
|
+
* **Aktualisert**: Sprachwechsler wird nicht angezeigt, wenn nur eine Sprache konfiguriert ist
|
|
8
|
+
* **Bugfix**: Einen Bug im Ausgabepfadname korrigiert
|
|
9
|
+
* **Bugfix**: Einen Bug im Sprachwechsler behoben
|
|
10
|
+
|
|
11
|
+
## 0.9.0 (26.01.2024)
|
|
12
|
+
|
|
13
|
+
* **Neu**: TEI Output hinzugefügt
|
|
14
|
+
* **Aktualisiert**: Bereits beantwortet Fragen überspringen
|
|
15
|
+
|
|
16
|
+
## 0.8.0 (12.01.2024)
|
|
17
|
+
|
|
18
|
+
* **Neu**: Unterstützung von Read the Docs als Publikationsplatform
|
|
19
|
+
* **Bugfix**: Softwareabhängigkeiten aktualisiert
|
|
20
|
+
|
|
21
|
+
## 0.7.0 (04.07.2023)
|
|
22
|
+
|
|
23
|
+
* **Neu**: Unterstützung für zentrale, statische Dateien
|
|
24
|
+
* **Bugfix**: Fehlende Fortschrittsanzeige hinzugefügt
|
|
25
|
+
|
|
26
|
+
## 0.6.1 (04.07.2023)
|
|
27
|
+
|
|
28
|
+
* **Aktualisiert**: Softwareabhängigkeiten aktualisiert
|
|
29
|
+
|
|
30
|
+
## 0.6.0 (04.07.2023)
|
|
31
|
+
|
|
32
|
+
* **Neu**: Zentrale Konfiguration und Inhaltsverzeichnis
|
|
33
|
+
|
|
34
|
+
## 0.5.0 (30.06.2023)
|
|
35
|
+
|
|
36
|
+
* **Neu**: Copier in die uEdition integriert
|
|
37
|
+
|
|
38
|
+
## 0.4.0 (26.06.2023)
|
|
39
|
+
|
|
40
|
+
* **Neu**: Sprachwechsler hinzugefügt
|
|
41
|
+
|
|
42
|
+
## 0.3.1 (22.06.2023)
|
|
43
|
+
|
|
44
|
+
* **Bugfix**: Sicherstellen dass der Ausgabepfad existiert
|
|
45
|
+
|
|
46
|
+
## 0.3.0 (22.06.2023)
|
|
47
|
+
|
|
48
|
+
* **Neu**: Startseite mit automatischer Spracherkennung integriert
|
|
49
|
+
|
|
50
|
+
## 0.2.1 (16.06.2023)
|
|
51
|
+
|
|
52
|
+
* **Bugfix**: Abschnittsformatierungsbug behoben
|
|
53
|
+
|
|
54
|
+
## 0.2.0 (16.06.2023)
|
|
55
|
+
|
|
56
|
+
* **Neu**: Das TEI Layout auf vertikal umgestellt
|
|
57
|
+
|
|
58
|
+
## 0.1.0 (13.06.2023)
|
|
59
|
+
|
|
60
|
+
* **Neu**: TEI Input hinzugefügt
|
|
61
|
+
|
|
62
|
+
## 0.0.3 (17.05.2023)
|
|
63
|
+
|
|
64
|
+
* **Bugfix**: Korrektur im Softwarepublikationsprozess
|
|
65
|
+
|
|
66
|
+
## 0.0.2 (17.05.2023)
|
|
67
|
+
|
|
68
|
+
* **Bugfix**: Ausgabepfad korrekt handhaben
|
|
69
|
+
|
|
70
|
+
## 0.0.1 (17.05.2023)
|
|
71
|
+
|
|
72
|
+
* **Neu**: Erste Version
|
|
@@ -33,7 +33,7 @@ $ copier copy https://github.com/uEdition/uEdition-project-template my-edition
|
|
|
33
33
|
🎤 What is the repository branch containing your μEdition?
|
|
34
34
|
main
|
|
35
35
|
|
|
36
|
-
Copying from template version 0.0
|
|
36
|
+
Copying from template version 0.1.0
|
|
37
37
|
create .
|
|
38
38
|
create toc.yml
|
|
39
39
|
create uEdition.yml
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
#
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
and configuring Jupyter Book projects can be used in the μEdition.
|
|
1
|
+
# Inhalte hinzufügen
|
|
2
|
+
|
|
3
|
+
Die μEdition nutzt [Jupyter Book](https://jupyterbook.org) um aus den Inhalten eine Webseite zu generieren,
|
|
4
|
+
welche dann veröffentlicht werden kann. Wenn die Webseite generiert wird, generiert die μEdition zuerst die
|
|
5
|
+
Webseiten für die einzelnen Sprachen und fügt dann die notwendigen Element hinzu um die einzelnen Sprachen
|
|
6
|
+
zusammenzufügen. Da die μEdition auf dem Jupyter Book aufbaut, sind der Großteil der Dokumentation des
|
|
7
|
+
Jupyter Book Projekts auch für die μEdition nutzbar. Der einzige Unterschied ist, dass die μEdition eine
|
|
8
|
+
Konfigurationsdatei und ein Inhaltsverzeichnisse für alle Sprachen nutzt.
|
|
10
9
|
|
|
11
10
|
## Structuring the μEdition
|
|
12
11
|
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# Eine μEdition erstellen
|
|
2
|
+
|
|
3
|
+
Jetzt wo alle Vorraussetzungen installiert sind, kann die erste μEdition erstellt werden. Auf der Kommandozeile
|
|
4
|
+
navigieren sie in den Ordner in dem die μEdition erstellt werden soll und führen sie folgenden Befehl aus:
|
|
5
|
+
|
|
6
|
+
:::{code-block} console
|
|
7
|
+
$ copier copy gh:uEdition/uEdition-project-template my-edition
|
|
8
|
+
:::
|
|
9
|
+
|
|
10
|
+
Ersetzen sie `my-edition` mit dem Ordernamen in dem die μEdition erstellt werden soll. Der Installationsvorgang
|
|
11
|
+
wird eine Reihe an Fragen stellen, um die neue μEdition zu konfigurieren und dann das μEditionsskeleton in dem
|
|
12
|
+
Ordern erzeugen.
|
|
13
|
+
|
|
14
|
+
Navigieren sie danach auf der Kommandozeile in den neuen Ordern und führen alle weiteren Befehle innerhalb des
|
|
15
|
+
Ordners aus.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
# Anleitung für Nutzer und Nutzerinnen
|
|
2
|
+
|
|
3
|
+
Willkommen in der Nutzeranleitung für die μEdition, welche die Herausgeber durch die Abläufe zum
|
|
4
|
+
{doc}`Erstellen einer neuen μEdition <create>`, {doc}`hinzufügen einer Sprache <language-add>`,
|
|
5
|
+
{doc}`Erstellung von Inhalten <content>` und {doc}`Veröffentlichen mittels GitHub Pages <publish>` führt.
|
|
6
|
+
|
|
7
|
+
Die Anleitung erwartet keine großen, technischen Vorkenntnisse, ausser Grundkenntnisse über die Nutzung der
|
|
8
|
+
Kommandozeile. Zusätzlich werden für die Veröffentlichung über GitHub Pages grundlegende Git Kenntnisse benötigt.
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# Installation
|
|
2
|
+
|
|
3
|
+
Die μEdition baut auf einer Reihe von Werkzeugen auf und um die erste μEdition zu erstellen, müssen diese Werkzeuge
|
|
4
|
+
installiert werden.
|
|
5
|
+
|
|
6
|
+
Die μEdition nutzt Python und unterstützt Versionen 3.10 und 3.11 [^python-version]. Bitte
|
|
7
|
+
[installieren sie die Python Version für ihr Betriebssystem](https://python.org/downloads).
|
|
8
|
+
|
|
9
|
+
Für die Erstellung einer μEdition wird ein Werkzeug namens [Copier](https://copier.readthedocs.io/en/stable/) genutzt.
|
|
10
|
+
Für die Installation aller weiteren Abhängigkeiten und um die verschiedenen μEdition Funktionen aufzurufen wird
|
|
11
|
+
[Hatch](https://hatch.pypa.io) genutzt.
|
|
12
|
+
|
|
13
|
+
Die einfachste Weise um beide zu installieren ist mittels [pipx](https://pypa.github.io/pipx/), welches
|
|
14
|
+
[von hier installiert werden kann](https://pypa.github.io/pipx/installation/). Nach der pipx installation nutzen sie
|
|
15
|
+
die folgenden zwei Befehle um Copier und Hatch zu installieren:
|
|
16
|
+
|
|
17
|
+
:::{code} console
|
|
18
|
+
$ pipx install copier
|
|
19
|
+
$ pipx install hatch
|
|
20
|
+
:::
|
|
21
|
+
|
|
22
|
+
Um zu überprüfen, dass die Installationen erfolgreich waren, nutzen sie die folgenden Befehle:
|
|
23
|
+
|
|
24
|
+
:::{code} console
|
|
25
|
+
$ copier
|
|
26
|
+
$ hatch
|
|
27
|
+
:::
|
|
28
|
+
|
|
29
|
+
Wenn beide Befehle eine Zusammenfassung der verfügbaren Optionen und Befehle für die zwei Werkzeuge anzeigen, dann
|
|
30
|
+
sind beide Werkzeuge korrekt installiert.
|
|
31
|
+
|
|
32
|
+
Um im Team zusammenzuarbeiten und für die GitHub Pages Veröffentlichungsfunktionalität, muss auch das Versionskontrollwerkzeug
|
|
33
|
+
[Git](https://git-scm.com/downloads) installiert sein. Eine vollständige Einführung in Git übersteigt den Platz hier,
|
|
34
|
+
aber es gibt viele gute Tutorials im Netz und die [offizielle Dokumentation](https://git-scm.com/doc) ist auch hilfreich.
|
|
35
|
+
|
|
36
|
+
[^python-version]: The μEdition wird mit Python 3.10 and 3.11 getested. Die μEdition funktioniert möglicherweise auch mit
|
|
37
|
+
neueren Python Versionen, ist aber auf diesen noch nicht getestet worden.
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# Eine Sprache hinzufügen
|
|
2
|
+
|
|
3
|
+
In der μEdition ist Mehrsprachigkeit eine Kernfunktionalität. Das bedeutet, dass selbst wenn die Edition nur in einer
|
|
4
|
+
einzigen Sprache veröffentlicht werden soll, diese Sprache trotzdem explizit konfiguriert werden muss.
|
|
5
|
+
|
|
6
|
+
Um der μEdition eine Sprache hinzuzufügen, führen sie folgenden Befehl aus:
|
|
7
|
+
|
|
8
|
+
:::{code-block} console
|
|
9
|
+
$ hatch run uEdition language add ORDERNAME
|
|
10
|
+
:::
|
|
11
|
+
|
|
12
|
+
Ersetzen sie `ORDNERNAME` mit dem Namen des Orderners in dem die Inhalte in der Sprache gespeichert werden. Der Vorgang
|
|
13
|
+
wird ein paar Detailfragen zu der neuen Sprache abfragen und dann ein Inhaltsskelet in dem Ordern erzeugen, welches
|
|
14
|
+
dann bereit ist um ediert zu werden.
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## 1.0.0 (31.01.2024)
|
|
4
|
+
|
|
5
|
+
* **New**: TEI output optional
|
|
6
|
+
* **Update**: JupyterBook updated to version 1
|
|
7
|
+
* **Update**: Hide the language switcher when only one language is configured
|
|
8
|
+
* **Bugfix**: Fix a bug in the output path naming
|
|
9
|
+
* **Bugfix**: fixed a bug in the language switcher
|
|
10
|
+
|
|
11
|
+
## 0.9.0 (26.01.2024)
|
|
12
|
+
|
|
13
|
+
* **New**: Add TEI Output
|
|
14
|
+
* **Update**: Skip previously answered questions
|
|
15
|
+
|
|
16
|
+
## 0.8.0 (12.01.2024)
|
|
17
|
+
|
|
18
|
+
* **New**: Support publishing via Read the Docs
|
|
19
|
+
* **Bugfix**: Dependency updates
|
|
20
|
+
|
|
21
|
+
## 0.7.0 (04.07.2023)
|
|
22
|
+
|
|
23
|
+
* **New**: Support shared static files
|
|
24
|
+
* **Bugfix**: Added missing progress update
|
|
25
|
+
|
|
26
|
+
## 0.6.1 (04.07.2023)
|
|
27
|
+
|
|
28
|
+
* **Update**: Compatability updates
|
|
29
|
+
|
|
30
|
+
## 0.6.0 (04.07.2023)
|
|
31
|
+
|
|
32
|
+
* **New**: Move to a shared central configuration and TOC
|
|
33
|
+
|
|
34
|
+
## 0.5.0 (30.06.2023)
|
|
35
|
+
|
|
36
|
+
* **New**: Directly integrate copier
|
|
37
|
+
|
|
38
|
+
## 0.4.0 (26.06.2023)
|
|
39
|
+
|
|
40
|
+
* **New**: Added the language switcher extension
|
|
41
|
+
|
|
42
|
+
## 0.3.1 (22.06.2023)
|
|
43
|
+
|
|
44
|
+
* **Bugfix**: Ensure that the output folder exists
|
|
45
|
+
|
|
46
|
+
## 0.3.0 (22.06.2023)
|
|
47
|
+
|
|
48
|
+
* **New**: Add a language-detecting landing page
|
|
49
|
+
|
|
50
|
+
## 0.2.1 (16.06.2023)
|
|
51
|
+
|
|
52
|
+
* **Bugfix**: Fix a section-wrapping bug
|
|
53
|
+
|
|
54
|
+
## 0.2.0 (16.06.2023)
|
|
55
|
+
|
|
56
|
+
* **New**: Switch the TEI layout to a vertical structure
|
|
57
|
+
|
|
58
|
+
## 0.1.0 (13.06.2023)
|
|
59
|
+
|
|
60
|
+
* **New**: Added basic TEI parsing
|
|
61
|
+
|
|
62
|
+
## 0.0.3 (17.05.2023)
|
|
63
|
+
|
|
64
|
+
* **Bugfix**: Fix the release process
|
|
65
|
+
|
|
66
|
+
## 0.0.2 (17.05.2023)
|
|
67
|
+
|
|
68
|
+
* **Bugfix**: Fix output path handling
|
|
69
|
+
|
|
70
|
+
## 0.0.1 (17.05.2023)
|
|
71
|
+
|
|
72
|
+
* **New**: Initial release
|
|
@@ -33,7 +33,7 @@ $ copier copy https://github.com/uEdition/uEdition-project-template my-edition
|
|
|
33
33
|
🎤 What is the repository branch containing your μEdition?
|
|
34
34
|
main
|
|
35
35
|
|
|
36
|
-
Copying from template version 0.0
|
|
36
|
+
Copying from template version 0.1.0
|
|
37
37
|
create .
|
|
38
38
|
create toc.yml
|
|
39
39
|
create uEdition.yml
|
|
@@ -4,7 +4,7 @@ With all the pre-requisites installed correctly, you are now ready to create you
|
|
|
4
4
|
navigate to the folder where you want to create your μEdition and run:
|
|
5
5
|
|
|
6
6
|
:::{code-block} console
|
|
7
|
-
$ copier copy
|
|
7
|
+
$ copier copy gh:uEdition/uEdition-project-template my-edition
|
|
8
8
|
:::
|
|
9
9
|
|
|
10
10
|
Replace `my-edition` with the name of the folder you want your edition to be created in. The setup process will ask
|
|
@@ -12,7 +12,7 @@ is used.
|
|
|
12
12
|
|
|
13
13
|
The easiest way to install both Copier and Hatch is via [pipx](https://pypa.github.io/pipx/), which you can
|
|
14
14
|
[install from here](https://pypa.github.io/pipx/installation/). When you have pipx installed, then on the commandline
|
|
15
|
-
run the following command to install Copier:
|
|
15
|
+
run the following command to install Copier and Hatch:
|
|
16
16
|
|
|
17
17
|
:::{code} console
|
|
18
18
|
$ pipx install copier
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "uedition_docs"
|
|
7
|
+
description = 'The μEdition Documentation'
|
|
8
|
+
requires-python = ">=3.10"
|
|
9
|
+
keywords = []
|
|
10
|
+
authors = [{ name = "Mark Hall", email = "mark.hall@work.room3b.eu" }]
|
|
11
|
+
classifiers = []
|
|
12
|
+
dependencies = []
|
|
13
|
+
version = "1.0.0"
|
|
14
|
+
|
|
15
|
+
[project.urls]
|
|
16
|
+
Documentation = "https://github.com/uEdition/uEdition/-#readme"
|
|
17
|
+
Issues = "https://github.com/uEdition/uEdition/-/issues"
|
|
18
|
+
Source = "https://github.com/uEdition/uEdition/-"
|
|
19
|
+
|
|
20
|
+
[tool.hatch.envs.default]
|
|
21
|
+
dependencies = ["uedition>=0.9.0",]
|
|
22
|
+
skip-install = true
|
|
23
|
+
|
|
24
|
+
[tool.hatch.envs.default.scripts]
|
|
25
|
+
build = "uEdition build {args}"
|
|
26
|
+
serve = "uEdition serve {args}"
|
|
27
|
+
update = "uEdition update {args}"
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "uEdition"
|
|
7
|
+
description = ''
|
|
8
|
+
readme = "README.md"
|
|
9
|
+
requires-python = ">=3.10"
|
|
10
|
+
license = "MIT"
|
|
11
|
+
keywords = []
|
|
12
|
+
authors = [{ name = "Mark Hall", email = "mark.hall@work.room3b.eu" }]
|
|
13
|
+
classifiers = [
|
|
14
|
+
"Development Status :: 4 - Beta",
|
|
15
|
+
"Programming Language :: Python",
|
|
16
|
+
"Programming Language :: Python :: 3.10",
|
|
17
|
+
"Programming Language :: Python :: 3.11",
|
|
18
|
+
"Programming Language :: Python :: Implementation :: CPython",
|
|
19
|
+
"Programming Language :: Python :: Implementation :: PyPy",
|
|
20
|
+
]
|
|
21
|
+
dependencies = [
|
|
22
|
+
"copier>=9.0.0,<10.0.0",
|
|
23
|
+
"jupyter-book>=1.0.0,<2.0.0",
|
|
24
|
+
"lxml>=4.9.2,<6.0.0",
|
|
25
|
+
"livereload",
|
|
26
|
+
"pydantic>=2.0.0,<3.0.0",
|
|
27
|
+
"pydantic-settings>=2.0.0,<3.0.0",
|
|
28
|
+
"PyYAML>=6.0.0,<7.0.0",
|
|
29
|
+
"typer[all]<1.0.0",
|
|
30
|
+
]
|
|
31
|
+
dynamic = ["version"]
|
|
32
|
+
|
|
33
|
+
[project.scripts]
|
|
34
|
+
uEdition = "uedition.cli:app"
|
|
35
|
+
|
|
36
|
+
[project.urls]
|
|
37
|
+
Documentation = "https://github.com/uEdition/uEdition#readme"
|
|
38
|
+
Issues = "https://github.com/uEdition/uEdition/issues"
|
|
39
|
+
Source = "https://github.com/uEdition/uEdition"
|
|
40
|
+
|
|
41
|
+
[project.entry-points."sphinx.builders"]
|
|
42
|
+
tei = "uedition.ext.tei.builder"
|
|
43
|
+
|
|
44
|
+
[tool.hatch.version]
|
|
45
|
+
path = "uedition/__about__.py"
|
|
46
|
+
|
|
47
|
+
[tool.hatch.envs.default]
|
|
48
|
+
extra-dependencies = ["coverage[toml]>=6.5", "pytest"]
|
|
49
|
+
|
|
50
|
+
[tool.hatch.envs.default.scripts]
|
|
51
|
+
docs-server = "cd docs && uEdition serve"
|
|
52
|
+
test = "pytest {args:tests}"
|
|
53
|
+
test-cov = "coverage run -m pytest {args:tests}"
|
|
54
|
+
cov-report = ["- coverage combine", "coverage report"]
|
|
55
|
+
cov = ["test-cov", "cov-report"]
|
|
56
|
+
|
|
57
|
+
[[tool.hatch.envs.all.matrix]]
|
|
58
|
+
python = ["3.10", "3.11"]
|
|
59
|
+
|
|
60
|
+
[tool.hatch.envs.lint]
|
|
61
|
+
|
|
62
|
+
dependencies = ["black>=23.1.0", "mypy>=1.0.0", "ruff>=0.0.243"]
|
|
63
|
+
detached = true
|
|
64
|
+
[tool.hatch.envs.lint.scripts]
|
|
65
|
+
typing = "mypy --install-types --non-interactive {args:uedition tests}"
|
|
66
|
+
style = ["ruff {args:.}", "black --check --diff {args:.}"]
|
|
67
|
+
fmt = ["black {args:.}", "ruff --fix {args:.}", "style"]
|
|
68
|
+
all = ["style", "typing"]
|
|
69
|
+
|
|
70
|
+
[tool.black]
|
|
71
|
+
target-version = ["py37"]
|
|
72
|
+
line-length = 120
|
|
73
|
+
skip-string-normalization = true
|
|
74
|
+
|
|
75
|
+
[tool.ruff]
|
|
76
|
+
target-version = "py37"
|
|
77
|
+
line-length = 120
|
|
78
|
+
select = [
|
|
79
|
+
"A",
|
|
80
|
+
"ARG",
|
|
81
|
+
"ANN",
|
|
82
|
+
"B",
|
|
83
|
+
"C",
|
|
84
|
+
"D",
|
|
85
|
+
"DTZ",
|
|
86
|
+
"E",
|
|
87
|
+
"EM",
|
|
88
|
+
"F",
|
|
89
|
+
"FBT",
|
|
90
|
+
"I",
|
|
91
|
+
"ICN",
|
|
92
|
+
"ISC",
|
|
93
|
+
"N",
|
|
94
|
+
"PLC",
|
|
95
|
+
"PLE",
|
|
96
|
+
"PLR",
|
|
97
|
+
"PLW",
|
|
98
|
+
"Q",
|
|
99
|
+
"RUF",
|
|
100
|
+
"S",
|
|
101
|
+
"T",
|
|
102
|
+
"TID",
|
|
103
|
+
"UP",
|
|
104
|
+
"W",
|
|
105
|
+
"YTT",
|
|
106
|
+
]
|
|
107
|
+
ignore = [
|
|
108
|
+
# Allow non-abstract empty methods in abstract base classes
|
|
109
|
+
"B027",
|
|
110
|
+
# Allow boolean positional values in function calls, like `dict.get(... True)`
|
|
111
|
+
"FBT003",
|
|
112
|
+
# Ignore checks for possible passwords
|
|
113
|
+
"S105",
|
|
114
|
+
"S106",
|
|
115
|
+
"S107",
|
|
116
|
+
# Ignore complexity
|
|
117
|
+
"C901",
|
|
118
|
+
"PLR0911",
|
|
119
|
+
"PLR0912",
|
|
120
|
+
"PLR0913",
|
|
121
|
+
"PLR0915",
|
|
122
|
+
# Ignore self annotations
|
|
123
|
+
"ANN101",
|
|
124
|
+
# Ignore conflicting documentation options
|
|
125
|
+
"D203",
|
|
126
|
+
"D213",
|
|
127
|
+
]
|
|
128
|
+
unfixable = [
|
|
129
|
+
# Don't touch unused imports
|
|
130
|
+
"F401",
|
|
131
|
+
]
|
|
132
|
+
|
|
133
|
+
[tool.ruff.isort]
|
|
134
|
+
known-first-party = ["uedition"]
|
|
135
|
+
|
|
136
|
+
[tool.ruff.flake8-tidy-imports]
|
|
137
|
+
ban-relative-imports = "all"
|
|
138
|
+
|
|
139
|
+
[tool.ruff.per-file-ignores]
|
|
140
|
+
# Tests can use magic values, assertions, and relative imports
|
|
141
|
+
"tests/**/*" = ["PLR2004", "S101", "TID252"]
|
|
142
|
+
|
|
143
|
+
[tool.coverage.run]
|
|
144
|
+
source_pkgs = ["uedition", "tests"]
|
|
145
|
+
branch = true
|
|
146
|
+
parallel = true
|
|
147
|
+
omit = ["uedition/__about__.py"]
|
|
148
|
+
|
|
149
|
+
[tool.coverage.paths]
|
|
150
|
+
uedition = ["uedition", "*/uedition/uedition"]
|
|
151
|
+
tests = ["tests", "*/uedition/tests"]
|
|
152
|
+
|
|
153
|
+
[tool.coverage.report]
|
|
154
|
+
exclude_lines = ["no cov", "if __name__ == .__main__.:", "if TYPE_CHECKING:"]
|
|
155
|
+
skip_covered = true
|
|
156
|
+
show_missing = true
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
"""Py.test fixtures."""
|
|
2
|
+
|
|
2
3
|
import os
|
|
4
|
+
from shutil import rmtree
|
|
5
|
+
from typing import Generator
|
|
3
6
|
|
|
4
7
|
from pytest import fixture
|
|
5
|
-
from shutil import rmtree
|
|
6
8
|
from typer import Typer
|
|
7
9
|
from typer.testing import CliRunner
|
|
8
|
-
from typing import Generator
|
|
9
10
|
|
|
10
11
|
|
|
11
12
|
@fixture
|
|
@@ -66,11 +67,11 @@ def multilang_app() -> Generator[Typer, None, None]:
|
|
|
66
67
|
cwd = os.getcwd()
|
|
67
68
|
try:
|
|
68
69
|
os.chdir("tests/fixtures/multilang")
|
|
69
|
-
if os.path.exists("docs"): #
|
|
70
|
+
if os.path.exists("docs"): # nocov
|
|
70
71
|
rmtree("docs")
|
|
71
|
-
if os.path.exists("en/_build"): #
|
|
72
|
+
if os.path.exists("en/_build"): # nocov
|
|
72
73
|
rmtree("en/_build")
|
|
73
|
-
if os.path.exists("de/_build"): #
|
|
74
|
+
if os.path.exists("de/_build"): # nocov
|
|
74
75
|
rmtree("de/_build")
|
|
75
76
|
from uedition.cli import app
|
|
76
77
|
from uedition.settings import reload_settings
|