From e26dca342f7f15c701d509ce299379c9f89912ee Mon Sep 17 00:00:00 2001 From: surdeus Date: Sun, 24 Mar 2024 14:09:24 +0500 Subject: [PATCH] fix: replaced calls of fmt.Fprintf with fmt.Fprint to prevent stupid inserts. --- install.sh | 3 +++ server/main.go | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) create mode 100755 install.sh diff --git a/install.sh b/install.sh new file mode 100755 index 0000000..f842149 --- /dev/null +++ b/install.sh @@ -0,0 +1,3 @@ +#!/bin/sh +# +go install ./cmd/rwiki diff --git a/server/main.go b/server/main.go index 735c96a..684dbe6 100644 --- a/server/main.go +++ b/server/main.go @@ -153,8 +153,8 @@ func (srv *Server) ProcessToHtml(urlPath, filePath string, bts []byte) ([]byte, } fmt.Fprint(&b, "
") - fmt.Fprintf(&b, string(main_section)) - fmt.Fprintf(&b, "
") + fmt.Fprint(&b, string(main_section)) + fmt.Fprint(&b, "") fmt.Fprint(&b, srv.pageFooter()) return b.Bytes(), nil }