Skip to content

Commit

Permalink
ran pre-commit
Browse files Browse the repository at this point in the history
  • Loading branch information
fabrue committed Aug 14, 2023
1 parent 7ca8b76 commit 9f28310
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 8 deletions.
9 changes: 9 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,12 @@ repos:
hooks:
- id: commitizen
stages: [commit-msg]
- repo: https://github.com/tekwizely/pre-commit-golang
rev: v1.0.0-rc.1
hooks:
- id: go-fmt
- id: go-mod-tidy
- id: go-imports
# FIX ME: See https://github.com/datadrivers/go-nexus-client/issues/122
# - id: go-vet
# - id: golangci-lint-mod
2 changes: 1 addition & 1 deletion nexus3/pkg/repository/bower/proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
)

const (
bowerProxyAPIEndpoint = repositoryBowerAPIEndpoint + "/proxy"
bowerProxyAPIEndpoint = repositoryBowerAPIEndpoint + "/proxy"
)

type RepositoryBowerProxyService struct {
Expand Down
1 change: 1 addition & 0 deletions nexus3/pkg/repository/bower/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (
const (
repositoryBowerAPIEndpoint = common.RepositoryAPIEndpoint + "/bower"
)

type RepositoryBowerService struct {
client *client.Client

Expand Down
2 changes: 1 addition & 1 deletion nexus3/pkg/repository/maven/proxy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ func getTestMavenProxyRepository(name string) repository.MavenProxyRepository {
Proxy: repository.Proxy{
ContentMaxAge: 1440,
MetadataMaxAge: 1440,
RemoteURL: "https://archive.ubuntu.com/ubuntu/",
RemoteURL: "https://archive.ubuntu.com/ubuntu/",
},
Storage: repository.Storage{
BlobStoreName: "default",
Expand Down
1 change: 0 additions & 1 deletion nexus3/pkg/repository/npm/group_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ func TestNpmGroupRepository(t *testing.T) {
repo.Group.MemberNames = append(repo.Group.MemberNames, testProxyRepo.Name)
}


err = service.Group.Create(repo)
assert.Nil(t, err)
generatedRepo, err := service.Group.Get(repo.Name)
Expand Down
2 changes: 1 addition & 1 deletion nexus3/schema/repository/bower.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ type BowerProxyRepository struct {
RoutingRuleName *string `json:"routingRuleName,omitempty"`

*Cleanup `json:"cleanup,omitempty"`
Bower `json:"bower"`
Bower `json:"bower"`
}

type Bower struct {
Expand Down
8 changes: 4 additions & 4 deletions nexus3/schema/repository/http_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,11 @@ type HTTPClientAuthentication struct {

// HTTPClientAuthenticationWithPreemptive ...
type HTTPClientAuthenticationWithPreemptive struct {
NTLMDomain string `json:"ntlmDomain,omitempty"`
NTLMHost string `json:"ntlmHost,omitempty"`
Password string `json:"password,omitempty"`
NTLMDomain string `json:"ntlmDomain,omitempty"`
NTLMHost string `json:"ntlmHost,omitempty"`
Password string `json:"password,omitempty"`
Type HTTPClientAuthenticationType `json:"type"`
Username string `json:"username,omitempty"`
Username string `json:"username,omitempty"`
// Whether to use pre-emptive authentication. Use with caution. Defaults to false.
Preemptive *bool `json:"preemptive,omitempty"`
}

0 comments on commit 9f28310

Please sign in to comment.