https://blackynonatech.pages.dev/posts/how-to-catch-errors-in-bash-scripts-on-linux/
How To Catch Errors In Bash Scripts On Linux