create

package
v0.2.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 11, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Command = &cobra.Command{
	Use:   "new",
	Short: "new [$modName]",
	Long: `
	Creates Neptune application.

	├── bootstrap
	│ ├── database.go		// init database,support drivers:mysql、clickhouse、postgreSql
	│ ├── grpc_server.go	// init grpc server,for discovery third party service
	│ ├── logger.go         // init logger
	│ ├── redis.go			//init redis connection pool
	│ ├── router.go         //init http router
	│ └── service.go        //registry grpc service
	├── config
	│ ├── app.yaml		    //app conf,appName、namespace、version、grpcPort、httpPort....
	│ ├── dev
	│ │ ├── config.yaml     //config center conf
	│ │ └── registry.yaml   //registry center conf
	│ ├── grey
	│ ├── prod
	│ └── test
	├── controller
	│ └── bar
	│     └── bar.go        //implementation gin handle (is optional)
	├── model
	│ ├── bar
	│ │ ├── log.go
	│ │ └── model.go       
	│ └── model.go          //model common variable
	├── service
	│ └── bar
	│     └── service.go    //implementation grpc interface
	├── Dockerfile          //multi-stage construction
	├── main.go 
	└── go.mod
`,
	Example: "neptune new github.com/no-mole/neptune",
	RunE: func(cmd *cobra.Command, args []string) error {
		return Run(args)
	},
}

Functions

func CmdRun

func CmdRun(cmd *exec.Cmd) (output string, err error)

func Run

func Run(args []string) error

Types

This section is empty.

Directories

Path Synopsis
template

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL