home · contact · privacy
Fix. master
authorChristian Heller <c.heller@plomlompom.de>
Fri, 4 Apr 2025 22:05:23 +0000 (00:05 +0200)
committerChristian Heller <c.heller@plomlompom.de>
Fri, 4 Apr 2025 22:05:23 +0000 (00:05 +0200)
bookworm/scripts/lib/copy_dirtree
bookworm/scripts/lib/expect_min_n_args [deleted file]
testing/scripts/lib/expect_min_n_args [changed from symlink to file mode: 0644]

index 438f4bd1520f78b2dff5ffb72b8860ce1de0c7b9..13c1c85ddd0edae6cb8d7abd6aa224425eff409c 100644 (file)
@@ -1,5 +1,7 @@
+. lib/expect_n_args
+
 copy_dirtree() {
-    expect_min_n_args 3 '(source root, target root, tags)' "$@"
+    expect_n_args 3 99 'SOURCE_ROOT TARGET_ROOT TAG...' $@
     SOURCE_ROOT="$1"
     TARGET_ROOT="$2"
     shift 2
diff --git a/bookworm/scripts/lib/expect_min_n_args b/bookworm/scripts/lib/expect_min_n_args
deleted file mode 100644 (file)
index 8f9c74d..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-expect_min_n_args() {
-    MIN_ARGS="$1"
-    EXPLAINER="$2"
-    shift 2
-    if [ "$#" -lt "${MIN_ARGS}" ]; then
-        echo "Need at least ${MIN_ARGS} arguments … ${EXPLAINER}"
-        false
-    fi
-}
deleted file mode 120000 (symlink)
index 0d272bc7b41c8488db2eea801ac864953d64f31b..0000000000000000000000000000000000000000
+++ /dev/null
@@ -1 +0,0 @@
-../../../bookworm/scripts/lib/expect_min_n_args
\ No newline at end of file
new file mode 100644 (file)
index 0000000000000000000000000000000000000000..8f9c74df6471e0d6e1403bfd38545fae6aa27841
--- /dev/null
@@ -0,0 +1,9 @@
+expect_min_n_args() {
+    MIN_ARGS="$1"
+    EXPLAINER="$2"
+    shift 2
+    if [ "$#" -lt "${MIN_ARGS}" ]; then
+        echo "Need at least ${MIN_ARGS} arguments … ${EXPLAINER}"
+        false
+    fi
+}