These functions can be used to supply an alert to the user that the evaluation of an expression succeeded or resulted in an error.
Usage
ft_beep_success_error(expr, success = 4, error = 2)
ft_ntfy_success_error(
expr,
success = "It Worked!",
error = "Better Check on Me."
)
ft_notify_success_error(
expr,
success = "All done!",
error = "Shit!",
image = NULL
)Details
Each of these functions takes an expression as the first argument, so it is possible to pipe into them, or just wrap the expression to run. They check if the evaluated expression returns an error or not, so they can give the correct feedback to the user.