MCPcopy Index your code
hub / github.com/jetify-com/devbox / handlePath

Function handlePath

internal/boxcli/create.go:97–110  ·  view source on GitHub ↗
(args []string, flags *createCmdFlags)

Source from the content-addressed store, hash-verified

95}
96
97func handlePath(args []string, flags *createCmdFlags) string {
98 path := pathArg(args)
99 wd, _ := os.Getwd()
100 if path == "" {
101 if flags.template != "" {
102 path = filepath.Join(wd, flags.template)
103 } else if flags.repo != "" && flags.subdir == "" {
104 path = filepath.Join(wd, filepath.Base(flags.repo))
105 } else if flags.repo != "" && flags.subdir != "" {
106 path = filepath.Join(wd, filepath.Base(flags.subdir))
107 }
108 }
109 return path
110}

Callers 1

runCreateCmdFunction · 0.85

Calls 1

pathArgFunction · 0.85

Tested by

no test coverage detected