title: hash each line in text file
body: <p>I'm trying to write a little script which will open a text file and give me an md5 hash for each line of text. For example I have a file with:</p>
  
  <pre><code>123
  213
  312
  </code></pre>
  
  <p>I want output to be:</p>
  
  <pre><code>ba1f2511fc30423bdbb183fe33f3dd0f
  6f36dfd82a1b64f668d9957ad81199ff
  390d29f732f024a4ebd58645781dfa5a
  </code></pre>
  
  <p>I'm trying to do this part in bash which will read each line:</p>
  
  <pre><code>#!/bin/bash
  #read.file.line.by.line.sh
  
  while read line
  do
  echo $line
  done
  </code></pre>
  
  <p>later on I do:</p>
  
  <pre><code>$ more 123.txt | ./read.line.by.line.sh | md5sum | cut -d '  ' -f 1
  </code></pre>
  
  <p>but I'm missing something here, does not work :(</p>
  
  <p>Maybe there is an easier way...</p>