Skip to content

Commit 10d38df

Browse files
authored
[update] update description for update command (#1115)
## Summary 1. update description for `update` command 2. add copyright automatically ## How was it tested? devbox update --help devbox global update --help
1 parent b3520fd commit 10d38df

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

internal/boxcli/update.go

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ package boxcli
66
import (
77
"github.com/pkg/errors"
88
"github.com/spf13/cobra"
9+
910
"go.jetpack.io/devbox"
1011
)
1112

@@ -18,10 +19,10 @@ func updateCmd() *cobra.Command {
1819

1920
command := &cobra.Command{
2021
Use: "update [pkg]...",
21-
Short: "Updates packages in your devbox",
22-
Long: "Updates one, many, or all packages in your devbox. " +
22+
Short: "Update packages in your devbox",
23+
Long: "Update one, many, or all packages in your devbox. " +
2324
"If no packages are specified, all packages will be updated. " +
24-
"Only updates versioned packages (e.g. `[email protected]`), not packages that are pinned to a nix channel (e.g. `python3`)",
25+
"Only update versioned packages (e.g. `[email protected]`), not packages that are pinned to a nix channel (e.g. `python3`)",
2526
PreRunE: ensureNixInstalled,
2627
RunE: func(cmd *cobra.Command, args []string) error {
2728
return updateCmdFunc(cmd, args, flags)
@@ -32,11 +33,7 @@ func updateCmd() *cobra.Command {
3233
return command
3334
}
3435

35-
func updateCmdFunc(
36-
cmd *cobra.Command,
37-
args []string,
38-
flags *updateCmdFlags,
39-
) error {
36+
func updateCmdFunc(cmd *cobra.Command, args []string, flags *updateCmdFlags) error {
4037
box, err := devbox.Open(flags.config.path, cmd.ErrOrStderr())
4138
if err != nil {
4239
return errors.WithStack(err)

internal/impl/update.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
// Copyright 2023 Jetpack Technologies Inc and contributors. All rights reserved.
2+
// Use of this source code is governed by the license in the LICENSE file.
3+
14
package impl
25

36
import (

0 commit comments

Comments
 (0)