Manage input file in main.