D
Dmitry V. Sabanin
Hi,
I have a strange problem with Dir.glob and directory symlinks on linux.
There's a directory:
$ ls -l /tmp/test
drwxr-xr-x 2 sdmitry sdmitry 80 Sep 13 10:40 test1
drwxr-xr-x 2 sdmitry sdmitry 80 Sep 13 10:40 test2
lrwxrwxrwx 1 sdmitry sdmitry 8 Sep 13 10:40 test3 -> ../test3
Each sub-directory has files with .file extension. Here's the problem:
$ ruby -e "p Dir.glob('**/*.file')"
["test1/test.file", "test2/test2.file"]
Why there's no test3 files in the result? And what simple workaround can I use
to get:
["test1/test.file", "test2/test2.file", "test3/test3.file"]
Thanks in advance,
I have a strange problem with Dir.glob and directory symlinks on linux.
There's a directory:
$ ls -l /tmp/test
drwxr-xr-x 2 sdmitry sdmitry 80 Sep 13 10:40 test1
drwxr-xr-x 2 sdmitry sdmitry 80 Sep 13 10:40 test2
lrwxrwxrwx 1 sdmitry sdmitry 8 Sep 13 10:40 test3 -> ../test3
Each sub-directory has files with .file extension. Here's the problem:
$ ruby -e "p Dir.glob('**/*.file')"
["test1/test.file", "test2/test2.file"]
Why there's no test3 files in the result? And what simple workaround can I use
to get:
["test1/test.file", "test2/test2.file", "test3/test3.file"]
Thanks in advance,