I needed the `dependsOn` statements so that the the tasks building the file collections would be properly called. When I tried passing either the output of a Jar task or a source sets `output`, the tasks generating that output weren't being called until I added the `dependsOn` statements. I had to double check that `dependsOn` would accept a null value, and it does, treating it as an empty collection.