<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Help with Perl in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176646#M459137</link>
    <description>Wow JRF you're good - that's it exactly, thanks yet again!</description>
    <pubDate>Thu, 21 May 2009 12:03:28 GMT</pubDate>
    <dc:creator>Yvonne Butler</dc:creator>
    <dc:date>2009-05-21T12:03:28Z</dc:date>
    <item>
      <title>Help with Perl</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176641#M459132</link>
      <description>Hi&lt;BR /&gt;&lt;BR /&gt;Some very kind forum members helped me put together this perl command below which I'm using to tell me how many files are in a directory which are 15 minutes older than the system date:&lt;BR /&gt;&lt;BR /&gt;perl -MFile::Find -le '$path=shift||qq(.);find(sub{print $File::Find::name if -f $_ &amp;amp;&amp;amp; -M _ &amp;gt;= ((15*60)/(60*60*24))},$path)'  /oraother/tes/comms/outtray | wc -l&lt;BR /&gt;&lt;BR /&gt;But what I need now is to modify this command to find out how many files that are not of a "0" byte size in a given directory.  I don't know Perl I'm afraid so don't know where to start.  Any suggestions would be very appreciated.&lt;BR /&gt;&lt;BR /&gt;Thanks</description>
      <pubDate>Thu, 21 May 2009 10:04:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176641#M459132</guid>
      <dc:creator>Yvonne Butler</dc:creator>
      <dc:date>2009-05-21T10:04:39Z</dc:date>
    </item>
    <item>
      <title>Re: Help with Perl</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176642#M459133</link>
      <description>Hi Yvonne:&lt;BR /&gt;&lt;BR /&gt;This is quite simple:&lt;BR /&gt;&lt;BR /&gt;#  perl -MFile::Find -le '$path=shift||qq(.);find(sub{print $File::Find::name if -f $_ &amp;amp;&amp;amp; -s _},$path)'&lt;BR /&gt;&lt;BR /&gt;...returns the non-zero size files.  Change the '-s' to '-z' to return files of zero size.&lt;BR /&gt;&lt;BR /&gt;For things like this, Perl is probably overkill.  You could simply do:&lt;BR /&gt;&lt;BR /&gt;# find . -type f ! -size 0c&lt;BR /&gt;&lt;BR /&gt;...to return files with size greater than zero and:&lt;BR /&gt;&lt;BR /&gt;# find . -type f -size 0c&lt;BR /&gt;&lt;BR /&gt;...to return files of size zero.&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Thu, 21 May 2009 10:35:19 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176642#M459133</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2009-05-21T10:35:19Z</dc:date>
    </item>
    <item>
      <title>Re: Help with Perl</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176643#M459134</link>
      <description>Hi,&lt;BR /&gt;To find out all zero bytes file use find command&lt;BR /&gt;&lt;BR /&gt;#find /home -type f -size 0c -exec ls -l {} \;&lt;BR /&gt;&lt;BR /&gt;Suraj</description>
      <pubDate>Thu, 21 May 2009 10:49:36 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176643#M459134</guid>
      <dc:creator>Suraj K Sankari</dc:creator>
      <dc:date>2009-05-21T10:49:36Z</dc:date>
    </item>
    <item>
      <title>Re: Help with Perl</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176644#M459135</link>
      <description>Ahh I haven't explained myself properly, what I actually need to still to get a total number of files in a given directory which are not of a zero byte size and which are 15 minutes or more older than the system date.</description>
      <pubDate>Thu, 21 May 2009 11:18:34 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176644#M459135</guid>
      <dc:creator>Yvonne Butler</dc:creator>
      <dc:date>2009-05-21T11:18:34Z</dc:date>
    </item>
    <item>
      <title>Re: Help with Perl</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176645#M459136</link>
      <description>Hi (again) Yvonne:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&amp;gt; what I actually need to still to get a total number of files in a given directory which are not of a zero byte size and which are 15 minutes or more older than the system date.&lt;BR /&gt;&lt;BR /&gt;Ah. that makes better sense:&lt;BR /&gt;&lt;BR /&gt;#  perl -MFile::Find -le '$path=shift||qq(.);find(sub{print $File::Find::name if -f $_ &amp;amp;&amp;amp; -s _ &amp;amp;&amp;amp; -M _ &amp;gt;= ((15*60)/(60*60*24))},$path)' &lt;BR /&gt;&lt;BR /&gt;...which simply adds (ands) the test for file size that I first showed.&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Thu, 21 May 2009 11:28:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176645#M459136</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2009-05-21T11:28:40Z</dc:date>
    </item>
    <item>
      <title>Re: Help with Perl</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176646#M459137</link>
      <description>Wow JRF you're good - that's it exactly, thanks yet again!</description>
      <pubDate>Thu, 21 May 2009 12:03:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/help-with-perl/m-p/5176646#M459137</guid>
      <dc:creator>Yvonne Butler</dc:creator>
      <dc:date>2009-05-21T12:03:28Z</dc:date>
    </item>
  </channel>
</rss>

