Skip to content

Commit

Permalink
fix issue w/ CI
Browse files Browse the repository at this point in the history
  • Loading branch information
Jared Allard committed Sep 2, 2022
1 parent b1cb3e5 commit b04d58f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion bootstrap.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions internal/common/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@ const FuncInit = "init"
//
// Developer note: Periodically check whether or not this functionality is exposed in
// a stdlib package by looking at the status of this accepted proposal:
//
// https://github.com/golang/go/issues/28089
//
// Whenever it's added in a stdlib package, use that instead of this because it's
// likely going to have been implemented in a manner that is a lot smarter than
// this implementation.
Expand Down
2 changes: 2 additions & 0 deletions internal/why/why.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,15 @@ var Analyzer = analysis.Analyzer{
// ensures it contains a // Why: <reason> immediately proceeding the nolint directive.
//
// For examples, see https://regex101.com/r/I41sfC/1
//
//nolint:gocritic // Why: It is suggesting bad syntax by not escaping each of the forward slashes.
var reNoLintWhy = regexp.MustCompile(`^nolint:\s?[\w\-,]+\s?\/\/\s?Why:\s?.+$`)

// reNoLintNaked is the regular expression that every nolint comment is checked against
// to ensure no naked nolint directives exist.
//
// For examples, see https://regex101.com/r/XJY8md/1
//
//nolint:gocritic // Why: It is suggesting bad syntax by not escaping each of the forward slashes.
var reNoLintNaked = regexp.MustCompile(`^nolint(\s*\/\/\s*Why:.*)*$`)

Expand Down

0 comments on commit b04d58f

Please sign in to comment.