note
rinceWind
<p>You have quotes inside your quotes. Try the following:</p>
<code>
print $sh->ls( qq(-l ./logs/ |grep -v "^d" |grep -v file1 | awk 'NR>1 { print \$9}'));
</code>
<p>Or indeed you could use <code>q()</code> as you're not doing any variable substitution inside the string.</p>
<p><strong>Update:</strong> yes I know it would be better for the OP to have coded this in perl rather than shelling out 4 subprocesses. Sometimes you need to start with where the person is. Spotting the quote nesting is something glaringly obvious to me - a kind of mistake anyone can make in coding, and worth pointing out.</p>
<!-- Node text goes above. Div tags should contain sig only -->
<div class="pmsig"><div class="pmsig-144850">
<p><small>--<br />[http://www.innercompass.co.uk/|wetware hacker]<br />(Qualified NLP Practitioner and Hypnotherapist)</small></p>
</div></div>
616727
616727