split the main script