summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShulhan <ms@kilabit.info>2020-02-14 11:59:22 +0700
committerShulhan <ms@kilabit.info>2020-02-14 11:59:22 +0700
commit9c53b6f8b9d0e7596c658ce2d89fb2a71cf0ce62 (patch)
treeda271f8369b587cf958deecae3aa16557fee88b9
parent65eae15930afa51ed233f4b1e41ef241a845cc58 (diff)
downloadciigo-9c53b6f8b9d0e7596c658ce2d89fb2a71cf0ce62.tar.xz
all: fix and suppress linter warnings
-rw-r--r--ciigo.go1
-rw-r--r--cmd/ciigo/main.go3
-rw-r--r--server.go2
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 <file>] [-address <ip:port>] serve <dir>
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)