Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix linting errors and add linter as CI check #102

Merged
merged 1 commit into from
Aug 23, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 3 additions & 1 deletion .github/workflows/linter.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
name: Lint

on: push
on:
push:
pull_request:

jobs:
check-modules:
Expand Down
3 changes: 1 addition & 2 deletions kubernetes.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ import (
"k8s.io/client-go/dynamic"
"k8s.io/client-go/kubernetes"
_ "k8s.io/client-go/plugin/pkg/client/auth" // Required for access to GKE and AKS
restclient "k8s.io/client-go/rest"
"k8s.io/client-go/tools/clientcmd"
"k8s.io/client-go/util/homedir"
)
Expand Down Expand Up @@ -149,7 +148,7 @@ func getClientConfig(options KubeConfig) (*rest.Config, error) {
kubeconfig := options.ConfigPath
if kubeconfig == "" {
// are we in-cluster?
config, err := restclient.InClusterConfig()
config, err := rest.InClusterConfig()
if err == nil {
return config, nil
}
Expand Down