We have a multi module project and we have a lot of places where .gitignore, .gitattribute files need to be considered as task inputs and outputs. I have observed that gradle by default excludes these patterns(everything in org.apache.tools.ant.DirectoryScanner.DEFAULTEXCLUDES).
To remove .gitignore from the exclusions list, I have tried to add the below line in settings.gradle.kts
The problem is this line seems to be working only from the second build which gets executed on a given gradle daemon process. For the first time build on a newly started daemon the above workaround doesn’t work.
I would like to know if there is any workaround which can be easily applicable for the whole multi module project.