<?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: printf in Operating System - Linux</title>
    <link>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040784#M95718</link>
    <description>You will have to install the Gnu version of find or choose to code your script in a more portable manner.</description>
    <pubDate>Tue, 17 Apr 2007 17:45:58 GMT</pubDate>
    <dc:creator>A. Clay Stephenson</dc:creator>
    <dc:date>2007-04-17T17:45:58Z</dc:date>
    <item>
      <title>printf</title>
      <link>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040783#M95717</link>
      <description>This command works for linux.&lt;BR /&gt;abcd@xyz:~&amp;gt; find /tmp -printf %m -maxdepth 0 | grep 1777&lt;BR /&gt;1777&lt;BR /&gt;&lt;BR /&gt;How can I achieve this in HP-UX 11.11? Thanks in advance.</description>
      <pubDate>Tue, 17 Apr 2007 17:26:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040783#M95717</guid>
      <dc:creator>Sanjiv Sharma_1</dc:creator>
      <dc:date>2007-04-17T17:26:25Z</dc:date>
    </item>
    <item>
      <title>Re: printf</title>
      <link>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040784#M95718</link>
      <description>You will have to install the Gnu version of find or choose to code your script in a more portable manner.</description>
      <pubDate>Tue, 17 Apr 2007 17:45:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040784#M95718</guid>
      <dc:creator>A. Clay Stephenson</dc:creator>
      <dc:date>2007-04-17T17:45:58Z</dc:date>
    </item>
    <item>
      <title>Re: printf</title>
      <link>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040785#M95719</link>
      <description>Here is what you need although I am not fond of non-portable solutions.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://hpux.its.tudelft.nl/hppd/hpux/Gnu/findutils-4.2.28/" target="_blank"&gt;http://hpux.its.tudelft.nl/hppd/hpux/Gnu/findutils-4.2.28/&lt;/A&gt;</description>
      <pubDate>Tue, 17 Apr 2007 17:51:24 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040785#M95719</guid>
      <dc:creator>A. Clay Stephenson</dc:creator>
      <dc:date>2007-04-17T17:51:24Z</dc:date>
    </item>
    <item>
      <title>Re: printf</title>
      <link>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040786#M95720</link>
      <description>Thanks. Is there any command/syntax through which I can get the permission of a file or directory in the number format?&lt;BR /&gt;like 1777 etc..</description>
      <pubDate>Tue, 17 Apr 2007 18:08:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040786#M95720</guid>
      <dc:creator>Sanjiv Sharma_1</dc:creator>
      <dc:date>2007-04-17T18:08:38Z</dc:date>
    </item>
    <item>
      <title>Re: printf</title>
      <link>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040787#M95721</link>
      <description>Neither -printf nor -maxdepth work on HP-UX.  You first will have to explain what they do?&lt;BR /&gt;&lt;BR /&gt;There is -depth option.&lt;BR /&gt;&lt;BR /&gt;I assume -printf %m prints the mode?  To do that, you need:&lt;BR /&gt;$ find /tmp -exec ll + | grep "^lrwxrwxrwx"</description>
      <pubDate>Tue, 17 Apr 2007 18:29:11 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040787#M95721</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2007-04-17T18:29:11Z</dc:date>
    </item>
    <item>
      <title>Re: printf</title>
      <link>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040788#M95722</link>
      <description>Hi Sanjiv:&lt;BR /&gt;&lt;BR /&gt;&amp;gt; Is there any command/syntax through which I can get the permission of a file or directory in the number format?&lt;BR /&gt;&lt;BR /&gt;# perl -le '$f=shift;printf("%04o %-s\n",(stat($f))[2] &amp;amp; 07777,$f)' file&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Tue, 17 Apr 2007 18:39:56 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040788#M95722</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2007-04-17T18:39:56Z</dc:date>
    </item>
    <item>
      <title>Re: printf</title>
      <link>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040789#M95723</link>
      <description>Hi (again) Sanjiv:&lt;BR /&gt;&lt;BR /&gt;Since you began this query with the piped output of 'find', here's another Perl variation that you can use in a pipeline:&lt;BR /&gt;&lt;BR /&gt;# find /path -type f -print|perl -nle  '{printf("%04o %-s\n",(stat($_))[2] &amp;amp; 07777,$_)}'  &lt;BR /&gt;&lt;BR /&gt;...OR (better yet) do everything in Perl:&lt;BR /&gt;&lt;BR /&gt;# perl -MFile::Find -le 'find(sub{printf("%04o %-s\n",(stat($_))[2] &amp;amp; 07777,$File::Find::name)},@ARGV)' /path&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 17 Apr 2007 19:51:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040789#M95723</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2007-04-17T19:51:15Z</dc:date>
    </item>
    <item>
      <title>Re: printf</title>
      <link>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040790#M95724</link>
      <description>Ok. I am using the following command for now:&lt;BR /&gt;ls -ld /tmp | grep "^drwxrwxrwt"&lt;BR /&gt;</description>
      <pubDate>Wed, 18 Apr 2007 00:36:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/printf/m-p/5040790#M95724</guid>
      <dc:creator>Sanjiv Sharma_1</dc:creator>
      <dc:date>2007-04-18T00:36:32Z</dc:date>
    </item>
  </channel>
</rss>

