the main script