title: Removing contiguous duplicate lines in vi without sorting
body: <p><a href="https://stackoverflow.com/questions/351161/removing-duplicate-rows-in-vi">This question</a> already addresses how to remove duplicate lines, but enforces that the list is sorted first. </p>
  
  <p>I would like to perform the remove contiguous duplicate lines step (i.e. <code>uniq</code>) without first sorting them.</p>
  
  <p>Example before:</p>
  
  <pre><code>Foo
  Foo
  Bar
  Bar
  </code></pre>
  
  <p>Example after:</p>
  
  <pre><code>Foo
  Bar
  </code></pre>