Skip to content

Commit ca4d880

Browse files
authored
[error ux] print script name upon error (#1547)
## Summary Printing the name to make it easier to identify the source of the error. ## How was it tested? Added this script ``` "hello": [ "echo \"hello\"", "exit 1" ], ``` ran `devbox run hello` and got: ``` Error: error running script "hello" in Devbox: exit status 1 ```
1 parent a7d5dd1 commit ca4d880

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/boxcli/run.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ func runScriptCmd(cmd *cobra.Command, args []string, flags runCmdFlags) error {
118118
}
119119

120120
if err := box.RunScript(cmd.Context(), script, scriptArgs); err != nil {
121-
return redact.Errorf("error running command in Devbox: %w", err)
121+
return redact.Errorf("error running script %q in Devbox: %w", script, err)
122122
}
123123
return nil
124124
}

0 commit comments

Comments
 (0)