Main script.