title: Automating file processing in bash with sequential numbering
body: <p>I have binary files in a directory containing timespec time stamps in following format:</p>
  
  <pre><code>timeStamps_from_callId_1
  timeStamps_from_callId_2
  timeStamps_from_callId_3
  timeStamps_from_callId_4
  timeStamps_from_callId_5
  ......
  </code></pre>
  
  <p>and I have a program called <code>timing_reader</code> in the same directory which has following format:</p>
  
  <pre><code>Usage: ./timing_reader &lt;timing-file&gt; [output file]
  </code></pre>
  
  <p>Now I want to automate the processing of these files through Bash scripting in such a way that each output file will be named as exactly the input file with .csv extension. For example:</p>
  
  <pre><code>./timing_reader timeStamps_from_callId_1 timeStamps_from_callId_1.csv
  </code></pre>
  
  <p>and</p>
  
  <pre><code>./timing_reader timeStamps_from_callId_2 timeStamps_from_callId_2.csv
  </code></pre>
  
  <p>and so on. I am a very basic user of Bash and have no experience of scripting whatsoever. Any sort of help is highly appreciated.</p>