entry is not always absolute while "fromFile" contract expects so
Hello,
in the documentation of "fromFile" the "source" should always be an absolute path (so as to allow the startsWith to work), however it seems that in our conditions glob.sync will return a path relative to current working dir, even though the path specified in the configuration is absolute.
https://github.com/mike-lischke/java2typescript/blob/b0f2057cbddcd2723bfe6c59bc922a9ed23eb7e4/src/conversion/JavaToTypeScript.ts#L248
https://github.com/mike-lischke/java2typescript/blob/b0f2057cbddcd2723bfe6c59bc922a9ed23eb7e4/src/PackageSourceManager.ts#L39C8-L39C9
I modified porduced code that way to make the tool work:
const source = PackageSourceManager.fromFile(path.resolve(currentDir, entry), path.resolve(currentDir, target), root, this.configuration.sourceReplace);
Best regards Armel
I see, thanks. If you like you could open a PR.
I hoped that I'd be able to do it quickly, but I am super loaded these days with other tasks