title: Csh adding strings to an array, whitespace troubles
body: <p>I’m having trouble doing something basic with csh. I have a string:</p>
  
  <pre><code>set newCmd = "$expansionCmd –option1 –option2 …"
  </code></pre>
  
  <p>And I’m creating an array of these strings, which I later want to execute:</p>
  
  <pre><code>set expansionCmdList = ($expansionCmdList[*] "$newCmd")   
  #I also tried without quotes, e.g. just $newCmd
  </code></pre>
  
  <p>Finally I try to iterate over and execute these commands:</p>
  
  <pre><code>foreach exCmd ($expansionCmdList) 
      `exCmd`    #execute it in the shell
  end 
  </code></pre>
  
  <p>However the problem is that the array entries are not the full string, but every part of the string separated by whitespace, i.e. the first entry is just “$expansionCmd”, the next entry would be “—option1” etc. </p>
  
  <p>Apologies in advance for using c shell, my company's code base is stuck with it.</p>