Ilkka Laukkanen | 1 May 2010 20:14
Picon

File#directory? docs

Hi,

I just noticed for the first time that if you have a symlink, say
"foo", that points at a directory, both

  File.symlink? 'foo'

and

  File.directory? 'foo'

return true. While this is a bit misleading in my opinion, it should
definitely be documented in File.directory?. So here's a tiny little
patch against trunk that documents this caveat in File#directory?.
What do you think?

--

-- 
Ilkka
Arif Jafer | 2 May 2010 11:08
Picon

Re: File#directory? docs

Sorry I didn't recognize neithor you nor i didn't understood your e-mail.
 
Your sincerely
Arif Jafer

 
On 5/1/10, Ilkka Laukkanen <ilkka.s.laukkanen <at> gmail.com> wrote:
Hi,

I just noticed for the first time that if you have a symlink, say
"foo", that points at a directory, both

File.symlink? 'foo'

and

File.directory? 'foo'

return true. While this is a bit misleading in my opinion, it should
definitely be documented in File.directory?. So here's a tiny little
patch against trunk that documents this caveat in File#directory?.
What do you think?

--
Ilkka


Roger Pack | 4 May 2010 19:58
Picon

Re: File#directory? docs

Sure submit a patch to redmine.ruby-lang.org

On Sat, May 1, 2010 at 12:14 PM, Ilkka Laukkanen
<ilkka.s.laukkanen <at> gmail.com> wrote:
> Hi,
>
> I just noticed for the first time that if you have a symlink, say
> "foo", that points at a directory, both
>
>  File.symlink? 'foo'
>
> and
>
>  File.directory? 'foo'
>
> return true. While this is a bit misleading in my opinion, it should
> definitely be documented in File.directory?. So here's a tiny little
> patch against trunk that documents this caveat in File#directory?.
> What do you think?
>
> --
> Ilkka
>

Ted Behling | 4 May 2010 20:21

Re: File#directory? docs

Roger -- I will probably have some doc patches to contribute at some point -- is Redmine the preferred way to
accept patches? 

-----Original Message-----
From: Roger Pack [mailto:rogerdpack2 <at> gmail.com] 
Sent: Tuesday, May 04, 2010 1:58 PM
To: ruby-doc <at> ruby-lang.org
Subject: Re: File#directory? docs

Sure submit a patch to redmine.ruby-lang.org

On Sat, May 1, 2010 at 12:14 PM, Ilkka Laukkanen <ilkka.s.laukkanen <at> gmail.com> wrote:
> Hi,
>
> I just noticed for the first time that if you have a symlink, say 
> "foo", that points at a directory, both
>
>  File.symlink? 'foo'
>
> and
>
>  File.directory? 'foo'
>
> return true. While this is a bit misleading in my opinion, it should 
> definitely be documented in File.directory?. So here's a tiny little 
> patch against trunk that documents this caveat in File#directory?.
> What do you think?
>
> --
> Ilkka
>

Roger Pack | 5 May 2010 18:22
Picon

Re: File#directory? docs

> Roger -- I will probably have some doc patches to contribute at some point -- is Redmine the preferred way to
accept patches?

Yeah.  They get merged in...typically quickly (not by me, but by other
maintainers).
I haven't had one that wasn't eventually merged (though some weren't fast).
-rp

Ilkka Laukkanen | 5 May 2010 11:08
Picon

Re: File#directory? docs

On Tue, May 4, 2010 at 8:58 PM, Roger Pack <rogerdpack2 <at> gmail.com> wrote:
> Sure submit a patch to redmine.ruby-lang.org

This is now bug #3249: http://redmine.ruby-lang.org/issues/show/3249

--

-- 
Ilkka


Gmane