Main script