added an option to resume run