In a desperate move to support symbolic links and broken symbolic links when copying and zipping and taring files, I have to start somewhere. I try to replace Zip.java and ZipCopyAction.java (using 8.0-rc-1) with my own custom implementation. But I run into a shadowing issue:
.../CustomZipCopyAction.java:77: error: incompatible types: org.gradle.internal.impldep.org.apache.commons.compress.archivers.zip.ZipArchiveOutputStream cannot be converted to org.apache.commons.compress.archivers.zip.ZipArchiveOutputStream zipOutStr = compressor.createArchiveOutputStream(zipFile); ^ 1 error
The exact source of the problem is this line: gradle/ZipCopyAction.java at 464b7dbb21b7bfbd86b19ef5b35b470f0429b444 · gradle/gradle · GitHub
zipOutStr = compressor.createArchiveOutputStream(zipFile);
It looks like the return type of the compressor is shadowed. How do I work around that given it’s mostly internal APIs? Any advice?