Miscellaneous tweaks and fixes (#2223)

* Miscellaneous tweaks and fixes

Mostly these were found by running golangci-lint with a bunch of linters
(more than the default set) enabled.

* fmt.Fprint -> fmt.Fprintln where possible

* Remove "nolint:staticcheck" for now
This commit is contained in:
Carlo Teubner authored and GitHub committed 2025-10-28 15:10:32 +11:00
1 parent b12cb33918
commit fc4b3637bb
11 files changed
+105 -108

No files matched your search

+1 -1
View File
@@ -233,7 +233,7 @@ func matchList(s string, words []string) (matches []compMatch, result string) {
}
func matchCmd(s string) (matches []compMatch, result string) {
words := append(gCmdWords, slices.Collect(maps.Keys(gOpts.cmds))...)
words := slices.Concat(gCmdWords, slices.Collect(maps.Keys(gOpts.cmds)))
slices.Sort(words)
matches, result = matchWord(s, slices.Compact(words))
return