Skip to content

Commit

Permalink
cli refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
enrichman committed Feb 4, 2025
1 parent 3be1be1 commit f3396e2
Show file tree
Hide file tree
Showing 6 changed files with 329 additions and 315 deletions.
25 changes: 6 additions & 19 deletions cli/cmds/cluster/cluster.go
Original file line number Diff line number Diff line change
@@ -1,29 +1,16 @@
package cluster

import (
"github.com/rancher/k3k/cli/cmds"
"github.com/urfave/cli/v2"
)

var subcommands = []*cli.Command{
{
Name: "create",
Usage: "Create new cluster",
Action: create,
Flags: append(cmds.CommonFlags, clusterCreateFlags...),
},
{
Name: "delete",
Usage: "Delete an existing cluster",
Action: delete,
Flags: append(cmds.CommonFlags, clusterDeleteFlags...),
},
}

func NewCommand() *cli.Command {
return &cli.Command{
Name: "cluster",
Usage: "cluster command",
Subcommands: subcommands,
Name: "cluster",
Usage: "cluster command",
Subcommands: []*cli.Command{
NewCreateCmd(),
NewDeleteCmd(),
},
}
}
286 changes: 0 additions & 286 deletions cli/cmds/cluster/create.go

This file was deleted.

Loading

0 comments on commit f3396e2

Please sign in to comment.