diff options
| author | Florian Fischer <florian.fischer@muhq.space> | 2023-12-16 13:35:54 +0100 |
|---|---|---|
| committer | Florian Fischer <florian.fischer@muhq.space> | 2023-12-16 13:35:54 +0100 |
| commit | 228e2a3e77d66b85608d362e05675145acd02a66 (patch) | |
| tree | 40c737b3e0722948525b5139f95abe2a382ab39d /scripts | |
| parent | 9fec03de1b21d68c26f145cd843c20c4ddccaacd (diff) | |
| download | unterricht-228e2a3e77d66b85608d362e05675145acd02a66.tar.gz unterricht-228e2a3e77d66b85608d362e05675145acd02a66.zip | |
improve lehrerversion detection
Do not build a lehrerversion of solution files and math
against the latex leading '\' for gap and solution macros.
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/lesson-make | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/scripts/lesson-make b/scripts/lesson-make index 64d8232d..11d8230d 100755 --- a/scripts/lesson-make +++ b/scripts/lesson-make @@ -26,9 +26,10 @@ if [[ -z "${targets[*]}" ]]; then ;; esac - if [[ "${source}" != *"test_lehrer.tex" ]] \ + if [[ "${source}" != *solution*.tex ]] \ + && [[ "${source}" != *"test_lehrer.tex" ]] \ && [[ "${source}" != *"test_loesung.tex" ]] \ - && grep -qe 'iflehrer\|lehrerversion\|gap\|solution' "${source}"; then + && grep -qe '\\iflehrer\|lehrerversion\|\\gap\|\\solution' "${source}"; then declare -a sus_targets=( "${new_targets[@]}" ) for sus_target in "${sus_targets[@]}"; do dir=$(dirname "${sus_target}") |
