From: Alia Amin Date: 2002-09-06T02:57:51+09:00 Subject: Re: $0 == __FILE__ idiom for Unix only? if __FILE__ == $0 ... end or if $0 == __FILE__ ... end both works on Windows. hth, alia Laurent Julliard wrote: > I have been using the Ruby idiom 'if $0 == __FILE__ ..... end' for > ages on Linux and now that I have to use some of my scripts on WIndows > it looks like this test doesn't work? > > Is this supposed to work on Unix/Linux only or on all platforms?? > > Thanks > > LJ > >