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

Use i18n for clusterctl command descriptions and update dep #202

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
51 changes: 50 additions & 1 deletion Gopkg.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions Gopkg.toml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@ required = [
name = "k8s.io/client-go"
branch = "release-6.0"

[[constraint]]
name = "k8s.io/kubernetes"
branch = "release-1.9"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

afaik we decided that for now cluster api would be released independent of k8s releases. does this tie us to a specific k8s version now?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe, I am not sure. I think it depends on which kubernetes library we use and if they differ in different versions.

I am using the same version as other k8s.io repositories. For example, k8s.io/apiserver etc are all using release-1.9. Later when we bump versions, I think we should bump them together.


# client-go needs this version
[[constraint]]
name = "github.com/Azure/go-autorest"
Expand Down
5 changes: 3 additions & 2 deletions clusterctl/cmd/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,13 @@ package cmd

import (
"github.com/spf13/cobra"
"k8s.io/kubernetes/pkg/kubectl/util/i18n"
)

var createCmd = &cobra.Command{
Use: "create",
Short: "Create a cluster API resource",
Long: `Create a cluster API resource with one command`,
Short: i18n.T("Create a cluster API resource"),
Long: i18n.T("Create a cluster API resource with one command"),
}

func init() {
Expand Down
5 changes: 3 additions & 2 deletions clusterctl/cmd/create_cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import (
"github.com/golang/glog"
"github.com/spf13/cobra"
"io/ioutil"
"k8s.io/kubernetes/pkg/kubectl/util/i18n"
"sigs.k8s.io/cluster-api/clusterctl/clusterdeployer"
clusterv1 "sigs.k8s.io/cluster-api/pkg/apis/cluster/v1alpha1"
"sigs.k8s.io/cluster-api/util"
Expand All @@ -35,8 +36,8 @@ var co = &CreateOptions{}

var createClusterCmd = &cobra.Command{
Use: "cluster",
Short: "Create kubernetes cluster",
Long: `Create a kubernetes cluster with one command`,
Short: i18n.T("Create kubernetes cluster"),
Long: i18n.T("Create a kubernetes cluster with one command"),
Run: func(cmd *cobra.Command, args []string) {
if co.Cluster == "" {
exitWithHelp(cmd, "Please provide yaml file for cluster definition.")
Expand Down
5 changes: 3 additions & 2 deletions clusterctl/cmd/delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,13 @@ package cmd

import (
"github.com/spf13/cobra"
"k8s.io/kubernetes/pkg/kubectl/util/i18n"
)

var deleteCmd = &cobra.Command{
Use: "delete",
Short: "Delete a cluster API resource",
Long: `Delete a cluster API resource with one command`,
Short: i18n.T("Delete a cluster API resource"),
Long: i18n.T("Delete a cluster API resource with one command"),
}

func init() {
Expand Down
5 changes: 3 additions & 2 deletions clusterctl/cmd/delete_cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ package cmd
import (
"github.com/golang/glog"
"github.com/spf13/cobra"
"k8s.io/kubernetes/pkg/kubectl/util/i18n"
"sigs.k8s.io/cluster-api/errors"
)

Expand All @@ -31,8 +32,8 @@ var do = &DeleteOptions{}
func NewCmdDeleteCluster() *cobra.Command {
cmd := &cobra.Command{
Use: "delete",
Short: "Delete kubernetes cluster",
Long: `Delete a kubernetes cluster with one command`,
Short: i18n.T("Delete kubernetes cluster"),
Long: i18n.T("Delete a kubernetes cluster with one command"),
Run: func(cmd *cobra.Command, args []string) {
if do.ClusterName == "" {
exitWithHelp(cmd, "Please provide cluster name.")
Expand Down
7 changes: 7 additions & 0 deletions vendor/github.com/chai2010/gettext-go/.travis.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

27 changes: 27 additions & 0 deletions vendor/github.com/chai2010/gettext-go/LICENSE

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

58 changes: 58 additions & 0 deletions vendor/github.com/chai2010/gettext-go/README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 13 additions & 0 deletions vendor/github.com/chai2010/gettext-go/examples/Makefile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

83 changes: 83 additions & 0 deletions vendor/github.com/chai2010/gettext-go/examples/hello.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 17 additions & 0 deletions vendor/github.com/chai2010/gettext-go/examples/hi/hi.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.
Binary file not shown.
Loading