puterboy has asked for the wisdom of the Perl Monks concerning the following question:
In perl, the following globs works:
< "abc/Two Words" >
< 'abc/Two Words' >
< abc/OneWord >
but the following globs don't:
< 'abc/OneWord' >
< 'abc/OneWord' >
< abc/Two Words >
However in bash, all of the above work except for:
abc/Two Words (where quotes left off)
So, I guess I don't understand why in Perl the quoting affects files with spaces differently from files without. While in bash, the workings of glob seem consistent.
Am I missing something or doing something wrong here?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Unexplained glob behavior vs. Bash shell
by moritz (Cardinal) on Nov 23, 2008 at 10:18 UTC | |
|
Re: Unexplained glob behavior vs. Bash shell
by ikegami (Patriarch) on Nov 23, 2008 at 16:16 UTC | |
|
Re: Unexplained glob behavior vs. Bash shell
by genehack (Beadle) on Nov 23, 2008 at 14:15 UTC |