diff options
| author | Florian Fischer <florian.fischer@muhq.space> | 2023-10-01 16:16:27 +0200 |
|---|---|---|
| committer | Florian Fischer <florian.fischer@muhq.space> | 2023-10-01 16:16:27 +0200 |
| commit | 8d98ee4cf8a8ed6c22c6a3278084c9207e431096 (patch) | |
| tree | 5b71d57cb42d6bced3b400b7be426421a94b3c35 /scripts | |
| parent | c255d04f9de58cd3fed774586e74dbe0040e537c (diff) | |
| download | unterricht-8d98ee4cf8a8ed6c22c6a3278084c9207e431096.tar.gz unterricht-8d98ee4cf8a8ed6c22c6a3278084c9207e431096.zip | |
match the source basename
find will include the path which will be ./ most of the time.
In order to not include the path in the pattern use only the
source basename in the switch statement.
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/lesson-make | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/lesson-make b/scripts/lesson-make index 6a4bfb9b..d3afcc2d 100755 --- a/scripts/lesson-make +++ b/scripts/lesson-make @@ -17,7 +17,7 @@ if [[ -z "${targets[*]}" ]]; then mapfile -t sources < <(eval "${FIND}") for source in "${sources[@]}"; do declare -a new_targets=() - case "${source}" in + case "$(basename "${source}")" in slides.md) new_targets+=("slides.pdf" "slides.pptx") ;; |
