Move the code into a dedicated file.