From: Chad Perrin Date: 2007-09-24T23:53:16+09:00 Subject: Re: "myscript.rb " - there's a blank in my name! On Mon, Sep 24, 2007 at 03:04:27PM +0900, Konrad Meyer wrote: > Quoth Todd Burch: > > Todd Burch wrote: > > > > > I've nevver know a blank character at the > > > end of a file name to be significant. > > > > > "never known" ... sorry. > > Yes, on *nix systems this is significant (probably windows too, I'm just > unfamiliar with it). You can also do "ruby myprog.rb\ " to escape the space. If I'm not mistaken, MacOS X uses bash as its default shell. That would mean you don't actually need to escape the space if you use quotes: $ ruby "myprog.rb " The same is true of (t)csh: > ruby 'myprog.rb ' In either shell, whether you use single or double quotes doesn't matter, and escaping the space (without quotes) also works. Whether or not the space is significant when first naming the file depends on how you name it. I believe that is true on MS Windows as well as systems such as MacOS X, various Linux distributions, SysV and BSD Unix systems, and so on -- though I don't have an MS Windows machine in front of me to test it. An extra space after a filename shouldn't produce a space character in the the filename itself when entered at a command line shell, but will probably do so with certain GUI-oriented means of naming files. -- CCD CopyWrite Chad Perrin [ http://ccd.apotheon.org ] McCloctnick the Lucid: "The first rule of magic is simple. Don't waste your time waving your hands and hopping when a rock or a club will do."