title: Rename all the files in the folder with increasing numbers
body: <p>I have a folder and inside that folder I have 10-15 files with arbitrary names.
  The filenames may include spaces in them. For example: <code>wWw.page.com  __ (576)_002</code>.
  In a terminal, when I press <code>w</code> and then <code>tab</code> the file name appears like this: <code>wWw.page.com\ \ __\ \(576\)_0.txt</code>.</p>
  
  <p>I want some script that will rename all my files like this <code>0.txt</code>, <code>1.txt</code>, <code>2.txt</code> and so on.</p>
  
  <p>My problem is: <code>wWw.page.com  __ (576)_002.txt file not found</code>.</p>
  
  <pre><code>index=0;
  for i in $(ls *.txt)
  do
      cp "${i}"  $index".txt" 
  done
  </code></pre>