diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 76f9f00d..9423275f 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -8,16 +8,20 @@ jobs: name: golangci-lint runs-on: ubuntu-latest steps: - - uses: actions/setup-go@fac708d6674e30b6ba41289acaab6d4b75aa0753 # v4.0.1 - with: - go-version: 1.19 - uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 with: fetch-depth: 0 + + - uses: actions/setup-go@fac708d6674e30b6ba41289acaab6d4b75aa0753 # v4.0.1 + with: + go-version: "1.20" + check-latest: true + cache: false + - name: golangci-lint - uses: golangci/golangci-lint-action@639cd343e1d3b897ff35927a75193d57cfcba299 # v3.6.0 + uses: golangci/golangci-lint-action@3a919529898de77ec3da873e3063ca4b10e7f5cc # v3.7.0 with: - version: v1.51.2 + version: v1.54.2 args: --verbose --timeout 10m --fix=false --new-from-rev=HEAD~ --config=.golangci.yml shellcheck: diff --git a/go.mod b/go.mod index 90c4970c..c4bbf8cc 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/temporalio/cli -go 1.19 +go 1.20 require ( github.com/alitto/pond v1.8.3 diff --git a/headersprovider/headers_provider.go b/headersprovider/headers_provider.go index 79c1d6b5..a39d9fac 100644 --- a/headersprovider/headers_provider.go +++ b/headersprovider/headers_provider.go @@ -2,8 +2,6 @@ package headersprovider import ( "context" - - h "github.com/temporalio/cli/headers" ) type HeadersProvider interface { @@ -18,18 +16,12 @@ type grpcHeaderProvider struct { headers map[string]string } -func newGrpcHeaderProvider(headers map[string]string) *grpcHeaderProvider { - provider := &grpcHeaderProvider{headers} - provider.headers[h.CallerTypeHeaderName] = h.CallerTypeHeaderCLI - return provider -} - func (a grpcHeaderProvider) GetHeaders(ctx context.Context) (map[string]string, error) { return a.headers, nil } func SetGRPCHeadersProvider(headers map[string]string) { - headersProvider = newGrpcHeaderProvider(headers) + headersProvider = &grpcHeaderProvider{headers} } func SetCurrent(hp HeadersProvider) {