Skip to content

Commit

Permalink
Use strings.Fields.
Browse files Browse the repository at this point in the history
  • Loading branch information
Gerrit91 committed Aug 24, 2023
1 parent 37c1edf commit 16992d5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/internal/utils/cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ func runCommandWithOutput(cmd *exec.Cmd, combinedOutput bool) (string, error) {
func (c *CmdExecutor) ExecWithStreamingOutput(ctx context.Context, command string) error {
command = os.ExpandEnv(command)

parts := strings.Split(command, " ")
parts := strings.Fields(command)

cmd := exec.CommandContext(ctx, parts[0], parts[1:]...) // nolint:gosec

Expand Down

0 comments on commit 16992d5

Please sign in to comment.