Skip to content

Commit

Permalink
Update lint-project.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
alovak authored Sep 21, 2023
1 parent ae227a1 commit 4bdd5e7
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion go/lint-project.sh
Original file line number Diff line number Diff line change
Expand Up @@ -257,14 +257,19 @@ linters:
linters-settings:
forbidigo:
forbid:
- '^panic$'
EOF
# Add some specific overrides
if [[ "$GOLANGCI_ALLOW_PRINT" != "yes" ]];
then
echo " - ^fmt\.Print.*$" >> "$configFilepath"
fi

# Add some specific overrides
if [[ "$GOLANGCI_ALLOW_PANIC" != "yes" ]];
then
echo " - ^panic$" >> "$configFilepath"
fi

# Run golangci-lint over non-test code first with forbidigo
./bin/golangci-lint $GOLANGCI_FLAGS run --config="$configFilepath" --verbose $GOLANGCI_TAGS

Expand Down

0 comments on commit 4bdd5e7

Please sign in to comment.