Y
Hacker News
new
|
ask
|
show
|
jobs
by
coldtea
3374 days ago
Well, Rust and Haskell might not be for the job, but sh and bash are clearly broken and in many ways.
-eu should have been the default from the start, for one.
1 comments
TorKlingberg
3374 days ago
Well, for scripts. set -e on an interactive shell is a bit of a challenge.
link
coldtea
3374 days ago
A shell could, and I'm going out on a limb here, check whether it's interactive or not and just enforce the -e in the appropriate case...
link
harryjo
3374 days ago
interactive commands should abort
the command
on unset variable
link
tomjakubowski
3374 days ago
"Abort command if variables are unset" is the -u flag, not -e. Both were mentioned long ago in this thread, but GP was talking about -e being painful for interactive shells. Imagine an interactive shell exiting as soon as a user's command failed!
link
dllthomas
3374 days ago
> Imagine an interactive shell exiting as soon as a user's command failed!
Hardcore mode.
link