Finally with a lot of dirty work we read file.