Skip to content

Commit

Permalink
modified linter settings
Browse files Browse the repository at this point in the history
  • Loading branch information
pacificcode committed Jan 14, 2025
1 parent 8d4947b commit 60bda6d
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 15 deletions.
18 changes: 10 additions & 8 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ linters-settings:
require-explanation: true
require-specific: true
gofumpt:
lang-version: "1.18"
lang-version: '1.18'
extra-rules: true
godox:
keywords:
Expand All @@ -33,14 +33,16 @@ linters-settings:
- ^[ ]*@
capital: true
depguard:
list-type: blacklist
include-go-root: true
includeGoStdLib: true
packages:
- github.com/sirupsen/logrus
rules:
main:
files:
- $all
deny:
- pkg: 'github.com/sirupsen/logrus'
desc: 'logging is standardised via yunikorn logger and zap'
packages-with-error-message:
- github.com/sirupsen/logrus: logging is allowed only by zerolog. Please use zerolog
- io/ioutil: "io/ioutil was deprecated in Go 1.16: https://tip.golang.org/doc/go1.16"
- io/ioutil: 'io/ioutil was deprecated in Go 1.16: https://tip.golang.org/doc/go1.16'
gomodguard:
blocked:
modules:
Expand Down Expand Up @@ -188,7 +190,7 @@ issues:
- linters:
- govet
- revive
text: "shadow: declaration of .err. shadows declaration"
text: 'shadow: declaration of .err. shadows declaration'
- path: mocks
linters:
- godot
Expand Down
4 changes: 2 additions & 2 deletions .trunk/trunk.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@ lint:
enabled:
- checkov@3.2.352
- osv-scanner@1.9.2
- renovate@39.106.0
- renovate@39.107.0
- trufflehog@3.88.2
- shellcheck@0.10.0
- gofmt@1.20.4
- taplo@0.9.3
- gitleaks@8.22.1
- gitleaks@8.23.0
- actionlint@1.7.6
- shfmt@3.6.0
- git-diff-check
Expand Down
9 changes: 4 additions & 5 deletions auth/azure.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,11 @@ var (
ErrInvalidToken = errors.New("received invalid bearer token")
)

// authTypeToGrantType maps authentication type to grant type which will be sent to DSV.
var authTypeToGrantType = map[AuthType]string{
FederatedAzure: "azure",
}

func (a *authorization) BuildAzureParams() (*requestBody, error) {
// authTypeToGrantType maps authentication type to grant type which will be sent to DSV.
var authTypeToGrantType = map[AuthType]string{
FederatedAzure: "azure",
}
resource := "https://management.azure.com/"
authorizer, err := azure.NewAuthorizerFromEnvironmentWithResource(resource)
if err != nil {
Expand Down

0 comments on commit 60bda6d

Please sign in to comment.