]> git.plutz.net Git - shellwiki/commitdiff
fallback handler for regular page names containing brackets
authorPaul Hänsch <paul@plutz.net>
Tue, 17 May 2022 12:15:06 +0000 (14:15 +0200)
committerPaul Hänsch <paul@plutz.net>
Tue, 17 May 2022 12:15:06 +0000 (14:15 +0200)
handlers/90_brackets.sh [new file with mode: 0755]

diff --git a/handlers/90_brackets.sh b/handlers/90_brackets.sh
new file mode 100755 (executable)
index 0000000..b6b2538
--- /dev/null
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+# spacial case for bracket pages that are not handled otherwise
+# attachment and edit (and really all) handlers should take precedence
+
+case "${PATH_INFO}" in
+  */\[*\]/*)
+    theme_page "${PATH_INFO}"
+    return 0
+    ;;
+esac
+
+return 1