This message was deleted.
# community-support
s
This message was deleted.
1
e
can you just use a FileCollection?
Copy code
files(
    rootProject.layout.projectDirectory.dir("path/to/${project.name}"),
    rootProject.layout.projectDirectory.dir("path/to/default")
).find(dir -> dir.isDirectory())
j
Seems to work and is more readable, thanks! 🙂
Thinking about it, I don't even need a
FileCollection
in this case and a list would have the same effect:
Copy code
[
    rootProject.layout.projectDirectory.dir("path/to/${project.name}"),
    rootProject.layout.projectDirectory.dir("path/to/default")
].find(dir -> dir.isDirectory())
Ah, scrap that.
files()
does way more and is preferable. 👍