title: Bash shell scripting syntactical issues: Target is not a directory?
body: <p>I am attempting to copy a file to a bunch of folders present in a directory. The folders have been saved in <code>propagation.txt</code> and are like:</p>
  
  <pre><code>sfproject/folder1
  sfproject/folder2
  </code></pre>
  
  <p>The code I am attempting to run is :</p>
  
  <pre><code>for x in `cat propagation.txt`
  do cp php.ini $x ; echo "Copied php.ini to $x"
  done
  echo "Finished"; 
  </code></pre>
  
  <p>However, it states that:</p>
  
  <pre><code>cp : 'target: 'propagation.txt' is not a text'
  </code></pre>
  
  <p>This is what propagation.txt consists of:</p>
  
  <pre><code>sfproject/apps/backend/modules/users/lib
  sfproject/apps/backend/templates
  sfproject/apps/frontend/config
  sfproject/apps/frontend/lib
  sfproject/apps/frontend/modules/EdboostSatGuide/actions
  sfproject/apps/frontend/modules/EdboostSatGuide/templates
  sfproject/apps/frontend/modules/dashboard/actions
  sfproject/apps/frontend/modules/dashboard/templates
  sfproject/apps/frontend/modules/quizzes/actions
  sfproject/apps/frontend/modules/quizzes/templates
  sfproject/apps/frontend/templates
  sfproject/cache/frontend/prod/config
  </code></pre>