title: How to loop through multiple folder and subfolders and remove file name start with abc.txt and 14 days old
body: <p>I have folder and subfolder. I need to loop through each folder and subfolder and remove or move the file names which start with abc.txt and 14 days old to temporary folder. My folder tree structure is:</p>
  
  <p><a href="https://i.stack.imgur.com/7kott.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/7kott.png" alt="folder and subfolder look"></a> </p>
  
  <p>The file may be inside the folder or subfolder <strong>'abc.txt'</strong></p>
  
  <p>I have used this below code but not working.</p>
  
  <ol>
  <li><p>I took the folder paths into a list.txt file using below command </p>
  
  <pre><code>find $_filepath -type d &gt;&gt; folderpathlist.txt
  </code></pre></li>
  <li><p>I pass the path list to below code to search and remove or move files to temporary folder </p>
  
  <pre><code>find folderpathlist.txt  -name "abc*" -mtime \+14 &gt;&gt;temp/test/
  </code></pre></li>
  </ol>
  
  <p>How do I achieve this scenario ?</p>