github.com/machinefi/w3bstream@v1.6.5-rc9.0.20240426031326-b8c7c4876e72/pkg/wsctl/cmd/project/project.go (about)

     1  package project
     2  
     3  import (
     4  	"github.com/spf13/cobra"
     5  
     6  	"github.com/machinefi/w3bstream/pkg/wsctl/client"
     7  	"github.com/machinefi/w3bstream/pkg/wsctl/config"
     8  )
     9  
    10  // Multi-language support
    11  var (
    12  	_projectCmdShorts = map[config.Language]string{
    13  		config.English: "Manage projects of W3bstream",
    14  		config.Chinese: "管理 W3bstream 系统里的 projects",
    15  	}
    16  )
    17  
    18  // NewProjectCmd represents the new project command.
    19  func NewProjectCmd(client client.Client) *cobra.Command {
    20  	cmd := &cobra.Command{
    21  		Use:   "project",
    22  		Short: client.SelectTranslation(_projectCmdShorts),
    23  	}
    24  	cmd.AddCommand(newProjectCreateCmd(client))
    25  	cmd.AddCommand(newProjectDeleteCmd(client))
    26  	return cmd
    27  }