you might also invest your script.
you can easily make it to run and then at the end also quit itself.

using commands exit or quit.
also, once the execution is finished, it actually exits automatically itself.
thus, there is something in your script that keeps hanging.
_________________________
!

download KiXnet