make error beep
Jason Quinn wrote on Aug 01, 2008
The new error function is nice but it is silently thown. I prefer to have scripts beep when they encounter an error (frequently I'm on another desktop while a script is running). I end up using code like this in my scripts
when I'd rather be able to do something like
Is it possible to add a feature like this to error?
This would be a worthwhile extension and could be done without breaking existing code.
Jason
if ( error condition )
{
beep()
error(1,"an error occured")
}
when I'd rather be able to do something like
if ( error condition )
error(1,"an error occured", beep+)
Is it possible to add a feature like this to error?
This would be a worthwhile extension and could be done without breaking existing code.
Jason
Mike Fitzpatrick wrote on Aug 01, 2008
Hi Jason,
Perhaps not quite with the syntax you suggest, but there is already an 'erract' environment variable in the ECL that controls behavior in error conditions (e.g. to show the trace or do an automatic flpr), so adding a new 'beep' behavior shouldn't be hard. I'm in the process of building the v2.14.1 patch systems now and will add it to the list.
Cheers,
-Mike
Perhaps not quite with the syntax you suggest, but there is already an 'erract' environment variable in the ECL that controls behavior in error conditions (e.g. to show the trace or do an automatic flpr), so adding a new 'beep' behavior shouldn't be hard. I'm in the process of building the v2.14.1 patch systems now and will add it to the list.
Cheers,
-Mike
Last post on Aug 01, 2008