script exiting when it\'s over