refactor(generator:controller): Move install script function to the script base object for use in other generators