mirror of
https://github.com/ossf/scorecard.git
synced 2024-08-15 19:30:40 +03:00
Fix lint issues: stylecheck linter (#487)
Co-authored-by: Naveen <172697+naveensrinivasan@users.noreply.github.com>
This commit is contained in:
parent
35fece6491
commit
26d17907a6
@ -49,7 +49,7 @@ linters:
|
||||
- sqlclosecheck
|
||||
- staticcheck
|
||||
- structcheck
|
||||
# - stylecheck
|
||||
- stylecheck
|
||||
- thelper
|
||||
- tparallel
|
||||
- typecheck
|
||||
|
@ -82,7 +82,7 @@ func ExtractFullpath(fn string) (string, bool) {
|
||||
|
||||
// Using the http.get instead of the lib httpClient because
|
||||
// the default checker.HTTPClient caches everything in the memory and it causes oom.
|
||||
func getHttpResponse(url string) (*http.Response, error) {
|
||||
func getHTTPResponse(url string) (*http.Response, error) {
|
||||
//https://securego.io/docs/rules/g107.html
|
||||
//nolint
|
||||
resp, err := http.Get(url)
|
||||
@ -122,7 +122,7 @@ func CheckFilesContent(checkName, shellPathFnPattern string,
|
||||
url = strings.Replace(url, "{archive_format}", "tarball/", 1)
|
||||
url = strings.Replace(url, "{/ref}", r.GetDefaultBranch(), 1)
|
||||
|
||||
resp, err := getHttpResponse(url)
|
||||
resp, err := getHTTPResponse(url)
|
||||
if err != nil {
|
||||
return checker.MakeRetryResult(checkName, err)
|
||||
}
|
||||
|
@ -153,7 +153,7 @@ func validateGitHubActionWorkflow(path string, content []byte, logf func(s strin
|
||||
Name string `yaml:"name"`
|
||||
Steps []struct {
|
||||
Name string `yaml:"name"`
|
||||
Id string `yaml:"id"`
|
||||
ID string `yaml:"id"`
|
||||
Uses string `yaml:"uses"`
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user