From 8d98ee4cf8a8ed6c22c6a3278084c9207e431096 Mon Sep 17 00:00:00 2001 From: Florian Fischer Date: Sun, 1 Oct 2023 16:16:27 +0200 Subject: 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. --- scripts/lesson-make | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts') 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") ;; -- cgit v1.2.3