chore(no-release): Fix godoc comments; enable godoclint
-
Please check this box if this contribution uses AI-generated content (including content generated by GitLab Duo features) as outlined in the GitLab DCO & CLA. As a benefit of being a GitLab Community Contributor, you receive complimentary access to GitLab Duo.
This MR fixes the godoclint
linter issues:
$ golangci-lint run
deployments_merge_requests.go:1:1: package godoc should start with "Package gitlab " (godoclint)
gitlab.go:17:1: package has more than one godoc ("gitlab") (godoclint)
job_token_scope.go:1:1: package godoc should start with "Package gitlab " (godoclint)
job_token_scope_test.go:1:1: package has more than one godoc ("gitlab") (godoclint)
request_options_test.go:1:1: package has more than one godoc ("gitlab") (godoclint)
resource_iteration_events_test.go:1:1: package has more than one godoc ("gitlab") (godoclint)
terraform_states.go:33:1: godoc should start with symbol name ("TerraformState") (godoclint)
terraform_states.go:43:1: godoc should start with symbol name ("TerraformStateVersion") (godoclint)
testing/client.go:1:1: package has more than one godoc ("testing") (godoclint)
9 issues:
* godoclint: 9
Details
GitLab is a library, and its documentation is an important part of it.
There must be an empty line before the copyright header and the package comment.
The -write_package_comment=false
flag disables writing // Package testing is a generated GoMock package.
in the generated mocks.
Before
Live at https://pkg.go.dev/gitlab.com/gitlab-org/api/client-go@v0.154.0:
Live at https://pkg.go.dev/gitlab.com/gitlab-org/api/client-go@v0.154.0/testing:
After
Run locally pkgsite .
and open http://localhost:8080/gitlab.com/gitlab-org/api/client-go:
http://localhost:8080/gitlab.com/gitlab-org/api/client-go/testing:
Edited by 🤖 GitLab Bot 🤖