See how Boundary would look with gofumpt applied (#853)

* See how Boundary would look with https://github.com/mvdan/gofumpt applied

Results of running `gofumpt -w -s .`

* Update tools file and Makefile for gofumpt

Co-authored-by: Jeff Mitchell <jeffrey.mitchell@gmail.com>
This commit is contained in:
Michael GaffneyandJeff Mitchell authored and GitHub committed 2021-01-07 10:02:32 -05:00
1 parent cca0fbea2b
commit 94cb79bbdd
237 files changed
+1567 -1529

No files matched your search

+4 -2
View File
@@ -57,8 +57,10 @@ func (n AccountReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type AccountCreateResult = AccountReadResult
type AccountUpdateResult = AccountReadResult
type (
AccountCreateResult = AccountReadResult
AccountUpdateResult = AccountReadResult
)
type AccountDeleteResult struct {
response *api.Response
+4 -2
View File
@@ -57,8 +57,10 @@ func (n AuthMethodReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type AuthMethodCreateResult = AuthMethodReadResult
type AuthMethodUpdateResult = AuthMethodReadResult
type (
AuthMethodCreateResult = AuthMethodReadResult
AuthMethodUpdateResult = AuthMethodReadResult
)
type AuthMethodDeleteResult struct {
response *api.Response
+4 -2
View File
@@ -57,8 +57,10 @@ func (n AuthTokenReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type AuthTokenCreateResult = AuthTokenReadResult
type AuthTokenUpdateResult = AuthTokenReadResult
type (
AuthTokenCreateResult = AuthTokenReadResult
AuthTokenUpdateResult = AuthTokenReadResult
)
type AuthTokenDeleteResult struct {
response *api.Response
+15 -13
View File
@@ -28,18 +28,20 @@ import (
"golang.org/x/time/rate"
)
const EnvBoundaryAddr = "BOUNDARY_ADDR"
const EnvBoundaryCACert = "BOUNDARY_CACERT"
const EnvBoundaryCAPath = "BOUNDARY_CAPATH"
const EnvBoundaryClientCert = "BOUNDARY_CLIENT_CERT"
const EnvBoundaryClientKey = "BOUNDARY_CLIENT_KEY"
const EnvBoundaryClientTimeout = "BOUNDARY_CLIENT_TIMEOUT"
const EnvBoundaryTLSInsecure = "BOUNDARY_TLS_INSECURE"
const EnvBoundaryTLSServerName = "BOUNDARY_TLS_SERVER_NAME"
const EnvBoundaryMaxRetries = "BOUNDARY_MAX_RETRIES"
const EnvBoundaryToken = "BOUNDARY_TOKEN"
const EnvBoundaryRateLimit = "BOUNDARY_RATE_LIMIT"
const EnvBoundarySRVLookup = "BOUNDARY_SRV_LOOKUP"
const (
EnvBoundaryAddr = "BOUNDARY_ADDR"
EnvBoundaryCACert = "BOUNDARY_CACERT"
EnvBoundaryCAPath = "BOUNDARY_CAPATH"
EnvBoundaryClientCert = "BOUNDARY_CLIENT_CERT"
EnvBoundaryClientKey = "BOUNDARY_CLIENT_KEY"
EnvBoundaryClientTimeout = "BOUNDARY_CLIENT_TIMEOUT"
EnvBoundaryTLSInsecure = "BOUNDARY_TLS_INSECURE"
EnvBoundaryTLSServerName = "BOUNDARY_TLS_SERVER_NAME"
EnvBoundaryMaxRetries = "BOUNDARY_MAX_RETRIES"
EnvBoundaryToken = "BOUNDARY_TOKEN"
EnvBoundaryRateLimit = "BOUNDARY_RATE_LIMIT"
EnvBoundarySRVLookup = "BOUNDARY_SRV_LOOKUP"
)
// Config is used to configure the creation of the client
type Config struct {
@@ -642,7 +644,7 @@ func (c *Client) NewRequest(ctx context.Context, method, requestPath string, bod
u.Path = ""
}
var host = u.Host
host := u.Host
// if SRV records exist (see
// https://tools.ietf.org/html/draft-andrews-http-srv-02), lookup the SRV
// record and take the highest match; this is not designed for
+4 -2
View File
@@ -57,8 +57,10 @@ func (n GroupReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type GroupCreateResult = GroupReadResult
type GroupUpdateResult = GroupReadResult
type (
GroupCreateResult = GroupReadResult
GroupUpdateResult = GroupReadResult
)
type GroupDeleteResult struct {
response *api.Response
+4 -2
View File
@@ -57,8 +57,10 @@ func (n HostCatalogReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type HostCatalogCreateResult = HostCatalogReadResult
type HostCatalogUpdateResult = HostCatalogReadResult
type (
HostCatalogCreateResult = HostCatalogReadResult
HostCatalogUpdateResult = HostCatalogReadResult
)
type HostCatalogDeleteResult struct {
response *api.Response
+4 -2
View File
@@ -58,8 +58,10 @@ func (n HostReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type HostCreateResult = HostReadResult
type HostUpdateResult = HostReadResult
type (
HostCreateResult = HostReadResult
HostUpdateResult = HostReadResult
)
type HostDeleteResult struct {
response *api.Response
+4 -2
View File
@@ -58,8 +58,10 @@ func (n HostSetReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type HostSetCreateResult = HostSetReadResult
type HostSetUpdateResult = HostSetReadResult
type (
HostSetCreateResult = HostSetReadResult
HostSetUpdateResult = HostSetReadResult
)
type HostSetDeleteResult struct {
response *api.Response
+1 -2
View File
@@ -12,8 +12,7 @@ func getOpts(opt ...Option) options {
type Option func(*options)
// options = how options are represented
type options struct {
}
type options struct{}
func getDefaultOptions() options {
return options{}
+1 -3
View File
@@ -12,9 +12,7 @@ const (
ErrOutputStringRequest = "output a string, please"
)
var (
LastOutputStringError *OutputStringError
)
var LastOutputStringError *OutputStringError
type OutputStringError struct {
*retryablehttp.Request
+4 -2
View File
@@ -60,8 +60,10 @@ func (n RoleReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type RoleCreateResult = RoleReadResult
type RoleUpdateResult = RoleReadResult
type (
RoleCreateResult = RoleReadResult
RoleUpdateResult = RoleReadResult
)
type RoleDeleteResult struct {
response *api.Response
+4 -2
View File
@@ -55,8 +55,10 @@ func (n ScopeReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type ScopeCreateResult = ScopeReadResult
type ScopeUpdateResult = ScopeReadResult
type (
ScopeCreateResult = ScopeReadResult
ScopeUpdateResult = ScopeReadResult
)
type ScopeDeleteResult struct {
response *api.Response
+4 -2
View File
@@ -65,8 +65,10 @@ func (n SessionReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type SessionCreateResult = SessionReadResult
type SessionUpdateResult = SessionReadResult
type (
SessionCreateResult = SessionReadResult
SessionUpdateResult = SessionReadResult
)
type SessionDeleteResult struct {
response *api.Response
+4 -2
View File
@@ -61,8 +61,10 @@ func (n TargetReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type TargetCreateResult = TargetReadResult
type TargetUpdateResult = TargetReadResult
type (
TargetCreateResult = TargetReadResult
TargetUpdateResult = TargetReadResult
)
type TargetDeleteResult struct {
response *api.Response
+4 -2
View File
@@ -57,8 +57,10 @@ func (n UserReadResult) GetResponseMap() map[string]interface{} {
return n.response.Map
}
type UserCreateResult = UserReadResult
type UserUpdateResult = UserReadResult
type (
UserCreateResult = UserReadResult
UserUpdateResult = UserReadResult
)
type UserDeleteResult struct {
response *api.Response