Currently if a user removes a file for a binding the generated C# code file is NOT removed until the end of the build. This is because the Incremental Clean does not happen until the end of the build process. So
we end up with old unused code in the assembly.
That this PR does is to add the ability for the generator to write a list of the files it generated during this run. This can then be compared by the calling app
with the list of current files and the deleted ones can then be removed.
This will be useful for supporting incremental build support for bindings.
This never was a problem, but now with binding happening inside the application project via AndroidLibrary or AndroidJavaSource it is important to make sure we do not include code that is no longer being generated. Especially for intellisense.
The simple text file format was chosen because all we need is a list of files. This can be loaded by MSBuild and compared directly against the results of
Currently if a user removes a file for a binding the generated C# code file is NOT removed until the end of the build. This is because the Incremental Clean does not happen until the end of the build process. So we end up with old unused code in the assembly.
That this PR does is to add the ability for the generator to write a list of the files it generated during this run. This can then be compared by the calling app with the list of current files and the deleted ones can then be removed.
This will be useful for supporting incremental build support for bindings.
This never was a problem, but now with binding happening inside the application project via
AndroidLibrary
orAndroidJavaSource
it is important to make sure we do not include code that is no longer being generated. Especially for intellisense.The simple text file format was chosen because all we need is a list of files. This can be loaded by MSBuild and compared directly against the results of
If we used the existing
.projitems
file there would be some additional work as we would need to parse the xml data.Additional Fixes
Fixed up some of the vscode tasks which no longer worked.