Skip to content

Conversation

@halotroop2288
Copy link
Member

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 .deleted on 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/Unwanted.class (deleted)

Marker files with the `.deleted` extension will be used to locate target files that should be deleted by the installer.

This can be used to delete files such as recipes for removed items or unused/relocated classes.
@halotroop2288
Copy link
Member Author

Just realized this still can't be used with anything but Java source files bruhhhhhh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant