read key/value from a file