initialize

package
v0.2.5 Latest Latest
Warning

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

Go to latest
Published: Dec 31, 2021 License: BSD-3-Clause Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var InitCmd = &cli.Command{
	Name:  "init",
	Usage: "initialize goplz",
	Flags: []cli.Flag{
		&cli.StringFlag{
			Name:  "virtual_go_path",
			Value: "",
			Usage: "The virtual GOPATH to fuse mount. If not set, will use '.<top-folder>-gopath'. Virtual GOPATH Should not be anywhere of the top folder.",
		},
	},
	Action: func(ctx *cli.Context) error {
		if conf.HasGoplzRc() {
			fmt.Println("Current working directory has already been initialized.")
			return nil
		}

		conf.CreateGoplzRc(ctx.String("virtual_go_path"))

		fmt.Println("Now you can run `goplz start`.")
		return nil
	},
}

InitCmd is for subcommand "init".

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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