Skip to content

Commit a9a9005

Browse files
committed
> stdbuf: failed to run command ‘eval’: No such file or directory
1 parent c9d47e1 commit a9a9005

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

src/run-with-summary

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ format_output() {
7777
}
7878

7979
# Get the command from arguments
80-
command="$@"
80+
command="$*"
8181

8282
# Secondary help guard: if exactly one argument and it is -h/--help, show usage and exit 0
8383
if [ "$command" = "-h" ] || [ "$command" = "--help" ]; then
@@ -98,9 +98,8 @@ start_time=$(date '+%s')
9898
temp_output_file=$(mktemp)
9999

100100
# Execute command and capture output while displaying it in realtime
101-
# Using stdbuf to force line buffering for non-interactive sessions
102101
set -o pipefail
103-
stdbuf -oL -eL eval "$command" 2>&1 | tee "$temp_output_file"
102+
eval "$command" 2>&1 | tee "$temp_output_file"
104103
exit_code=${PIPESTATUS[0]}
105104

106105
# Read the output from temporary file

0 commit comments

Comments
 (0)