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

Function installCmd

internal/boxcli/install.go:23–43  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

21}
22
23func installCmd() *cobra.Command {
24 flags := installCmdFlags{}
25 command := &cobra.Command{
26 Use: "install",
27 Short: "Install all packages mentioned in devbox.json",
28 Args: cobra.MaximumNArgs(0),
29 PreRunE: ensureNixInstalled,
30 RunE: func(cmd *cobra.Command, args []string) error {
31 return installCmdFunc(cmd, flags)
32 },
33 }
34
35 flags.config.register(command)
36 command.Flags().BoolVar(
37 &flags.tidyLockfile, "tidy-lockfile", false,
38 "Fix missing store paths in the devbox.lock file.",
39 // Could potentially do more in the future.
40 )
41
42 return command
43}
44
45func installCmdFunc(cmd *cobra.Command, flags installCmdFlags) error {
46 // Check the directory exists.

Callers 2

globalCmdFunction · 0.85
RootCmdFunction · 0.85

Calls 2

installCmdFuncFunction · 0.85
registerMethod · 0.45

Tested by

no test coverage detected