simplify parseHashFile
switch to if
add trailing newlines