Handle Deleted Files #6
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Builds on #5. Adds a way to create and handle deleted file markers.
This is useful in any case where you need to completely delete a file, such as deleting assets that cause errors or relocating classes.
The process is the same as patching a file, except instead of copying the original and editing it, you create an empty file in the same package as the original, with the same name, and the the extension
.deletedon the end.Example:
Original (in decompiled jar):
com/example/Unwanted.java(4kb)Patched (in project source set):
com/example/Unwanted.java.deleted(0b)Source Patch (output of
gradle createSourcePatch):com/example/Unwanted.java.deleted(0b)Bin Patch (output of
gradle createBinPatch):com/example/Unwanted.java.deleted(0b)Result (in installer output jar):
com/example/(deleted)Unwanted.class