discovery: Recurse into directories pointed to by a symlink.
authorLudovic Courtès <ludo@gnu.org>
Mon, 3 Jul 2017 21:35:56 +0000 (23:35 +0200)
committerLudovic Courtès <ludo@gnu.org>
Mon, 3 Jul 2017 21:51:23 +0000 (23:51 +0200)
commit960c6ce96d746cf19829ad26e092ec5dad2a5c62
tree81894ab71d17bc3995507acf4654af5379d7bac1
parentcc1dfc202f2fefb6c2eb9467d1fc90a9154550c9
discovery: Recurse into directories pointed to by a symlink.

Reported by Christopher Baines <mail@cbaines.net>
and Alex Kost <alezost@gmail.com>
at <https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00290.html>.

* guix/discovery.scm (scheme-files): When ENTRY is a symlink that
doesn't end in '.scm', call 'stat' and recurse if it points to a
directory.
* tests/discovery.scm ("scheme-modules recurses in symlinks to
directories"): New test.
guix/discovery.scm
tests/discovery.scm