diff --git a/Makefile b/Makefile index 3986e58..8dbf722 100644 --- a/Makefile +++ b/Makefile @@ -35,7 +35,7 @@ lint: $(REVIVE) @echo "Checking vet..." @go vet ./... 2>&1 | tee -a lint.log @echo "Checking lint..." - @$(REVIVE) -config ./tools/revive.toml ./... 2>&1 | tee -a lint.log + @$(REVIVE) -set_exit_status ./... 2>&1 | tee -a lint.log @echo "Checking for unresolved FIXMEs..." @git grep -i fixme | grep -v -e '^vendor/' -e '^Makefile' | tee -a lint.log @[ ! -s lint.log ] diff --git a/internal/stack/doc.go b/internal/stack/doc.go new file mode 100644 index 0000000..9179a56 --- /dev/null +++ b/internal/stack/doc.go @@ -0,0 +1,22 @@ +// Copyright (c) 2017-2023 Uber Technologies, Inc. +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. + +// Package stack is used for parsing stacks from `runtime.Stack`. +package stack diff --git a/tools/revive.toml b/tools/revive.toml deleted file mode 100644 index 94223ce..0000000 --- a/tools/revive.toml +++ /dev/null @@ -1,6 +0,0 @@ -# Configuration for revive, see https://revive.run/docs#configuration - -# Sets the severity of the `package-comments` rule to "error". -[rule.package-comments] - Disabled = true - diff --git a/tools/tools.go b/tools/tools.go index 7d7855a..4143a37 100644 --- a/tools/tools.go +++ b/tools/tools.go @@ -25,5 +25,5 @@ package tools import ( // Tools we use during development. - _ "github.com/mgechev/revive" + _ "github.com/mgechev/revive" )