From 9c53b6f8b9d0e7596c658ce2d89fb2a71cf0ce62 Mon Sep 17 00:00:00 2001 From: Shulhan Date: Fri, 14 Feb 2020 11:59:22 +0700 Subject: all: fix and suppress linter warnings --- ciigo.go | 1 + cmd/ciigo/main.go | 3 +-- server.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ciigo.go b/ciigo.go index 01763e3..03ab75e 100644 --- a/ciigo.go +++ b/ciigo.go @@ -24,6 +24,7 @@ const ( markupKindMarkdown ) +//nolint: gochecknoglobals var ( defExcludes = []string{ `.*\.adoc$`, diff --git a/cmd/ciigo/main.go b/cmd/ciigo/main.go index 59fc6c6..ad91ff3 100644 --- a/cmd/ciigo/main.go +++ b/cmd/ciigo/main.go @@ -113,6 +113,5 @@ ciigo [-template ] [-address ] serve Serve all files inside directory "dir" using HTTP server, watch changes on markup files and convert them to HTML files automatically. - If the address is not set, its default to ":8080". -`) + If the address is not set, its default to ":8080".`) } diff --git a/server.go b/server.go index 19ca055..14a0722 100644 --- a/server.go +++ b/server.go @@ -240,7 +240,7 @@ func (srv *Server) onSearch(res http.ResponseWriter, req *http.Request, reqBody } fhtml := &fileHTML{ - Body: template.HTML(bufSearch.String()), + Body: template.HTML(bufSearch.String()), //nolint: gosec } err = srv.htmlg.tmpl.Execute(&buf, fhtml) -- cgit v1.3