<?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: command find + sort in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403538#M201319</link>
    <description>Unfortunatelly "ls" is not consistent with displaying dates.&lt;BR /&gt; &lt;BR /&gt;Here is a one liner that should work-&lt;BR /&gt;find . -name "*.old" | perl -ne 'chomp; print STDOUT (-M $_),"\t",$_,"\n"' | sort -n | cut -f2 | xargs -n1 ll -d&lt;BR /&gt; &lt;BR /&gt;This works by getting the age of the file, prepending to the filename, then calling sort, then calling cut (to remove the file age), then xargs to do "ll" command.&lt;BR /&gt; &lt;BR /&gt;HTH&lt;BR /&gt; &lt;BR /&gt;-- Rod Hills</description>
    <pubDate>Tue, 19 Oct 2004 13:07:14 GMT</pubDate>
    <dc:creator>Rodney Hills</dc:creator>
    <dc:date>2004-10-19T13:07:14Z</dc:date>
    <item>
      <title>command find + sort</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403534#M201315</link>
      <description>as I can order por date&lt;BR /&gt;&lt;BR /&gt;$ find . -name *.old -exec ls -ltr {} \;|more&lt;BR /&gt;-rw-r--r--   1 named    named        351 Aug  3  2001 ./a/a/aaaimar.com.old&lt;BR /&gt;-rw-r--r--   1 named    named        360 Jul 12  2001 ./a/a/aaci.org.ar.old&lt;BR /&gt;-rw-r--r--   1 named    named        408 Mar 14  2003 ./a/a/aacolombo.com.old&lt;BR /&gt;-rw-r--r--   1 named    named        410 Mar 14  2003 ./a/a/aaconcagua.com.old&lt;BR /&gt;-rw-r--r--   1 named    named        664 Mar 14  2003 ./a/a/aaehsa.com.ar.old&lt;BR /&gt;-rw-r--r--   1 named    named        603 Nov 12  2003 ./a/a/aaqct.com.ar.old&lt;BR /&gt;</description>
      <pubDate>Tue, 19 Oct 2004 12:42:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403534#M201315</guid>
      <dc:creator>Jairo Campana</dc:creator>
      <dc:date>2004-10-19T12:42:06Z</dc:date>
    </item>
    <item>
      <title>Re: command find + sort</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403535#M201316</link>
      <description>Not too sure if you are just providing info or you are having trouble...&lt;BR /&gt;&lt;BR /&gt;Try this:&lt;BR /&gt;&lt;BR /&gt;find ./ -name *.old | xargs ls -ltr {} \;|more&lt;BR /&gt;&lt;BR /&gt;Rgds...Geoff</description>
      <pubDate>Tue, 19 Oct 2004 12:50:08 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403535#M201316</guid>
      <dc:creator>Geoff Wild</dc:creator>
      <dc:date>2004-10-19T12:50:08Z</dc:date>
    </item>
    <item>
      <title>Re: command find + sort</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403536#M201317</link>
      <description>Not too sure if you are just providing info or you are having trouble&lt;BR /&gt;********************************&lt;BR /&gt;yes, work with errors&lt;BR /&gt;find ./ -name *.old | xargs ls -ltr {} \;|more&lt;BR /&gt;&lt;BR /&gt;-rw-r--r--   1 named    named        347 Aug 15  2001 ./a/r/aroxt.com.old&lt;BR /&gt;-rw-r--r--   1 named    named        361 Aug 15  2001 ./a/r/arihernandez.com.old&lt;BR /&gt;-rw-r--r--   1 named    named        353 Aug 21  2001 ./a/r/arqsovic.com.old&lt;BR /&gt;--More--{}: No such file or directory&lt;BR /&gt;;: No such file or directory&lt;BR /&gt;{}: No such file or directory&lt;BR /&gt;;: No such file or directory</description>
      <pubDate>Tue, 19 Oct 2004 12:56:31 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403536#M201317</guid>
      <dc:creator>Jairo Campana</dc:creator>
      <dc:date>2004-10-19T12:56:31Z</dc:date>
    </item>
    <item>
      <title>Re: command find + sort</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403537#M201318</link>
      <description>What about:&lt;BR /&gt;&lt;BR /&gt;find ./ -name *.old | xargs ls -ltr |more&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Rgds...Geoff</description>
      <pubDate>Tue, 19 Oct 2004 13:03:55 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403537#M201318</guid>
      <dc:creator>Geoff Wild</dc:creator>
      <dc:date>2004-10-19T13:03:55Z</dc:date>
    </item>
    <item>
      <title>Re: command find + sort</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403538#M201319</link>
      <description>Unfortunatelly "ls" is not consistent with displaying dates.&lt;BR /&gt; &lt;BR /&gt;Here is a one liner that should work-&lt;BR /&gt;find . -name "*.old" | perl -ne 'chomp; print STDOUT (-M $_),"\t",$_,"\n"' | sort -n | cut -f2 | xargs -n1 ll -d&lt;BR /&gt; &lt;BR /&gt;This works by getting the age of the file, prepending to the filename, then calling sort, then calling cut (to remove the file age), then xargs to do "ll" command.&lt;BR /&gt; &lt;BR /&gt;HTH&lt;BR /&gt; &lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Tue, 19 Oct 2004 13:07:14 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403538#M201319</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2004-10-19T13:07:14Z</dc:date>
    </item>
    <item>
      <title>Re: command find + sort</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403539#M201320</link>
      <description>Geoffs solution is the most sound, although it won't work if you have a lot of files.&lt;BR /&gt; &lt;BR /&gt;xargs will process the filenames in chunks, so that each chunk will be sorted, but not sorted as a whole.&lt;BR /&gt; &lt;BR /&gt;my 2 cents...&lt;BR /&gt; &lt;BR /&gt;-- Rod Hills&lt;BR /&gt; &lt;BR /&gt;PS- gnu find command, available on the software porting and archive centre, has extended capabilities that might be of use to solve your problem.</description>
      <pubDate>Tue, 19 Oct 2004 20:16:51 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403539#M201320</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2004-10-19T20:16:51Z</dc:date>
    </item>
    <item>
      <title>Re: command find + sort</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403540#M201321</link>
      <description>we can also use,&lt;BR /&gt;&lt;BR /&gt; ls -ltr `find . -name "*.old"` | more&lt;BR /&gt;&lt;BR /&gt;HTH.</description>
      <pubDate>Wed, 20 Oct 2004 00:40:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/command-find-sort/m-p/3403540#M201321</guid>
      <dc:creator>Muthukumar_5</dc:creator>
      <dc:date>2004-10-20T00:40:33Z</dc:date>
    </item>
  </channel>
</rss>

