Skip to content

Commit ed0ba1f

Browse files
authored
.ci: lint for TIP: comments (#47939)
These comments are typically left over when `skaff` is used to outline an initial resource, data source, or list resource. Uses the [`godox`](https://golangci-lint.run/docs/linters/configuration/#godox) linter rather than rolling our own custom analyzer or using semgrep for a simple regexp search.
1 parent 5814370 commit ed0ba1f

3 files changed

Lines changed: 5 additions & 3 deletions

File tree

.ci/.golangci3.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ linters:
88
# !! only add f-m linters here
99
- goconst
1010
- gocritic
11+
- godox
1112
- govet
1213
- importas
1314
- ineffassign
@@ -26,6 +27,10 @@ linters:
2627
- opinionated
2728
- performance
2829
- style
30+
godox:
31+
keywords:
32+
# for lingering skaff TIP comments
33+
- TIP
2934
importas:
3035
no-unaliased: true
3136
alias:

internal/service/chatbot/slack_workspace_data_source_test.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@ import (
1515

1616
func TestAccChatbotSlackWorkspaceDataSource_basic(t *testing.T) {
1717
ctx := acctest.Context(t)
18-
// TIP: This is a long-running test guard for tests that run longer than
19-
// 300s (5 min) generally.
2018
if testing.Short() {
2119
t.Skip("skipping long-running test in short mode")
2220
}

internal/service/logs/metric_filter_list.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ func (l *metricFilterListResource) List(ctx context.Context, request list.ListRe
6464
logging.ResourceAttributeKey(names.AttrLogGroupName): logGroupName,
6565
})
6666

67-
// TIP: -- 4. Get information about a resource from AWS
6867
stream.Results = func(yield func(list.ListResult) bool) {
6968
input := cloudwatchlogs.DescribeMetricFiltersInput{
7069
LogGroupName: aws.String(logGroupName),

0 commit comments

Comments
 (0)