Added functionality for script command line running