Use Bash trap command to ensure your script always exits in a predictable manner. Read this tutorial to learn about Bash trap syntax and use.
Use Bash trap command to ensure your script always exits in a predictable manner. Read this tutorial to learn about Bash trap syntax and use.