From 581be0955022a6d62babf20a3ac2682f30094347 Mon Sep 17 00:00:00 2001 From: Kai Moritz Date: Thu, 7 May 2026 23:24:31 +0200 Subject: [PATCH] WIP --- src/main/resources/import-in-hugo.sh | 26 ++++++++++++++++++-------- 1 file changed, 18 insertions(+), 8 deletions(-) diff --git a/src/main/resources/import-in-hugo.sh b/src/main/resources/import-in-hugo.sh index 5776ea7..a40e226 100644 --- a/src/main/resources/import-in-hugo.sh +++ b/src/main/resources/import-in-hugo.sh @@ -85,10 +85,15 @@ while [[ $# -gt 0 ]]; do then shift else - URL_BASE="${2%%/}" - URL_BASE="${URL_BASE##/}" - URL_BASE="/$URL_BASE" - shift 2 + if [[ ! "$2" =~ ^-- ]] + then + URL_BASE="${2%%/}" + URL_BASE="${URL_BASE##/}" + URL_BASE="/$URL_BASE" + shift 2 + else + shift + fi fi ;; --archived) @@ -97,10 +102,15 @@ while [[ $# -gt 0 ]]; do then shift else - URL_BASE="${2%%/}" - URL_BASE="${URL_BASE##/}" - URL_BASE="/$URL_BASE" - shift 2 + if [[ ! "$2" =~ ^-- ]] + then + URL_BASE="${2%%/}" + URL_BASE="${URL_BASE##/}" + URL_BASE="/$URL_BASE" + shift 2 + else + shift + fi fi ;; --canonical) -- 2.39.5