mirror of
https://github.com/hashicorp/packer.git
synced 2026-02-26 19:41:06 -05:00
This change replaces the deprecated constructors `New` with `NewService`. Static check before the change ``` ⇶ golangci-lint run --disable-all --no-config --enable=staticcheck | grep SA1019 | grep google - post-processor/googlecompute-import/post-processor.go:183:18: SA1019: storage.New is deprecated: please use NewService instead. To provide a custom HTTP client, use option.WithHTTPClient. If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead. (staticcheck) - post-processor/googlecompute-import/post-processor.go:219:18: SA1019: compute.New is deprecated: please use NewService instead. To provide a custom HTTP client, use option.WithHTTPClient. If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead. (staticcheck) - post-processor/googlecompute-import/post-processor.go:273:18: SA1019: storage.New is deprecated: please use NewService instead. To provide a custom HTTP client, use option.WithHTTPClient. If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead. (staticcheck) - builder/googlecompute/driver_gce.go:127:18: SA1019: compute.New is deprecated: please use NewService instead. To provide a custom HTTP client, use option.WithHTTPClient. If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead. (staticcheck) - builder/googlecompute/driver_gce.go:132:25: SA1019: oslogin.New is deprecated: please use NewService instead. To provide a custom HTTP client, use option.WithHTTPClient. If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead. (staticcheck) ``` Static check after change ``` [go-1.15.2] [1] wilken@automaton in ~/Development/packer/ ⇶ golangci-lint run --disable-all --no-config --enable=staticcheck | grep SA1019 | grep google ``` |
||
|---|---|---|
| .. | ||
| artifact.go | ||
| artifact_test.go | ||
| post-processor.go | ||
| post-processor.hcl2spec.go | ||