title: Find and move files to appropriate directories using shell script
body: <p>I have below setup and I want to find and move files.</p>
  
  <p>I have files <code>/home/backup/abc/123.wav</code> and  <code>/home/backup/xyz/456.wav</code>.
  Same directories exist at <code>/usr/src/abc</code>  and <code>/usr/src/xyz</code> which does not have any files.</p>
  
  <p>I want to find .wav files from home_dir and move them to particular dest_dir.</p>
  
  <p>So 123.wav should move to /usr/src/abc and 456.wav should move to /usr/src/xyz.
  I am using below command for that.</p>
  
  <pre><code>home_dir=/home/backup/
  dest_dir=/usr/src/
  cd $home_dir &amp;&amp; find . -iname "*.wav" -exec mv {} $dest_dir \;
  </code></pre>
  
  <p>But all the .wav files(123.wav and 456.wav) moved to /usr/src and not to its respective directories(/usr/src/abc  and /usr/src/xyz).</p>
  
  <p>Is it possible to achieve what I want ?
  Please suggest.</p>