From: Konrad Meyer Date: 2007-09-25T03:41:26+09:00 Subject: Re: "myscript.rb " - there's a blank in my name! --nextPart1918760.eQEIE7I9nh Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Quoth Chad Perrin: > On Mon, Sep 24, 2007 at 03:04:27PM +0900, Konrad Meyer wrote: > > Quoth Todd Burch: > > > Todd Burch wrote: > > >=20 > > > > I've nevver know a blank character at the > > > > end of a file name to be significant. > > > >=20 > > > "never known" ... sorry. > >=20 > > 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=20 space. >=20 > 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: >=20 > $ ruby "myprog.rb " >=20 > The same is true of (t)csh: >=20 > > ruby 'myprog.rb ' >=20 > In either shell, whether you use single or double quotes doesn't matter, > and escaping the space (without quotes) also works. >=20 > 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. >=20 > --=20 > CCD CopyWrite Chad Perrin [ http://ccd.apotheon.org ] > McCloctnick the Lucid: "The first rule of magic is simple. Don't waste yo= ur > time waving your hands and hopping when a rock or a club will do." The quotes were for quoting the entire command, not the argument. Escaping works without quotes. Tab-completion will should you the escaped form (sans quotes). Regards, =2D-=20 Konrad Meyer http://konrad.sobertillnoon.com/ --nextPart1918760.eQEIE7I9nh Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (GNU/Linux) iD8DBQBG+AS7CHB0oCiR2cwRAgbQAJ0fQ6qrhps6OoR3aFLLAyLmXwVo1QCfYRE4 rhbm7g3WzQmBqq198zh6Jzo= =2aCD -----END PGP SIGNATURE----- --nextPart1918760.eQEIE7I9nh--