From 7dc7ac78e6ba55c4ebf4f201481092ece0970a98 Mon Sep 17 00:00:00 2001 From: Joe Carstairs Date: Tue, 8 Sep 2026 09:47:16 +0100 Subject: pre-format gemtext syntax if in

---
 http/bin/gmi2upphtml | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

(limited to 'http/bin/gmi2upphtml')

diff --git a/http/bin/gmi2upphtml b/http/bin/gmi2upphtml
index 0d16c56..8638d0a 100755
--- a/http/bin/gmi2upphtml
+++ b/http/bin/gmi2upphtml
@@ -103,6 +103,12 @@ pp \"\${SHARE}\"/components/meta.upphtml
 
 while read line
 do
+  if [ $is_in_preformatted_block -ne 0 ]
+  then
+    echo "$(escape_upphtml "${line}")"
+    continue
+  fi
+
   if [ "$(echo $line | sed "s/[[:space:]]//g")" = "" ]
   then
     continue
@@ -178,12 +184,6 @@ do
     continue
   fi
 
-  if [ $is_in_preformatted_block -ne 0 ]
-  then
-    echo "$(escape_upphtml "${line}")"
-    continue
-  fi
-
   close_all_open_blocks
   echo "

$(escape_upphtml "${line}")

" done -- cgit v1.2.3