Updated file input to readline