fix(deps): update diffpatch to v2.1.0.43#340
Open
Toffikk wants to merge 7 commits intoPaperMC:mainfrom
Open
Conversation
This commit updates diffpatch to the *currently* latest version and migrates previous inputs and outputs to use the Multi/Single Input/Output interfaces Everything was tested locally and using a dev bundle and no regressions nor changes in patch output have been noticed. The reasoning for this update is to keep up-to-date with the latest improvements in the library (such as fixing ghost patches)
Contributor
Author
|
rebased and updated the library again! |
Contributor
Author
|
updated diffpatch to latest again. the new update allows us to output rejected hunks as patches |
There was a problem hiding this comment.
Pull request overview
This PR updates the project’s DiffPatch dependency to 2.1.0.43 (and the new io.codechicken.* packages) and migrates patch/diff invocations to the new Multi/Single Input/Output APIs used by DiffPatch v2.
Changes:
- Bump DiffPatch from
1.5.0.30→2.1.0.43and update repository/shading config for the new group. - Migrate
DiffOperation/PatchOperationcall sites from*Path(...)APIs tobaseInput(...)/changedInput(...)/patchedOutput(...)/patchesOutput(...). - Adjust logging/summary access patterns for the new DiffPatch result model (notably nullable
summary).
Reviewed changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| paperweight-userdev/src/main/kotlin/io/papermc/paperweight/userdev/internal/setup/action/SetupMacheSourcesAction.kt | Switch PatchOperation to new DiffPatch v2 Input/Output APIs for archive patching. |
| paperweight-userdev/src/main/kotlin/io/papermc/paperweight/userdev/internal/setup/action/ApplyDevBundlePatchesAction.kt | Switch dev bundle patch apply to new Input/Output APIs (archive → folder output). |
| paperweight-lib/src/main/kotlin/io/papermc/paperweight/tasks/GenerateDevBundle.kt | Switch DiffOperation usage to new Input/Output APIs when generating patches. |
| paperweight-core/src/main/kotlin/io/papermc/paperweight/core/tasks/patching/RebuildSingleFilePatches.kt | Switch DiffOperation usage to new Input/Output APIs for single-file patch rebuild. |
| paperweight-core/src/main/kotlin/io/papermc/paperweight/core/tasks/patching/RebuildFilePatches.kt | Switch DiffOperation usage + logging to Gradle logger; adapt to nullable summary. |
| paperweight-core/src/main/kotlin/io/papermc/paperweight/core/tasks/patching/ApplySingleFilePatches.kt | Switch PatchOperation usage to new Input/Output APIs and rejects output API. |
| paperweight-core/src/main/kotlin/io/papermc/paperweight/core/tasks/patching/ApplyFilePatchesFuzzy.kt | Update PatchMode import to new package. |
| paperweight-core/src/main/kotlin/io/papermc/paperweight/core/tasks/patching/ApplyFilePatches.kt | Switch PatchOperation usage + logging; adapt to nullable summary and new rejects output API. |
| paperweight-core/src/main/kotlin/io/papermc/paperweight/core/tasks/SetupMinecraftSources.kt | Switch PatchOperation usage to new Input/Output APIs + logger-based logging. |
| paperweight-core/src/main/kotlin/io/papermc/paperweight/core/taskcontainers/UpstreamConfigTasks.kt | Update PatchMode import to new package. |
| gradle/libs.versions.toml | Bump DiffPatch version coordinate. |
| buildSrc/src/main/kotlin/config-publish.gradle.kts | Update relocation list to io.codechicken.* packages. |
| buildSrc/src/main/kotlin/config-kotlin.gradle.kts | Update repository content filter to include io.codechicken. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
paperweight-core/src/main/kotlin/io/papermc/paperweight/core/tasks/SetupMinecraftSources.kt
Show resolved
Hide resolved
paperweight-core/src/main/kotlin/io/papermc/paperweight/core/tasks/patching/ApplyFilePatches.kt
Show resolved
Hide resolved
...weight-core/src/main/kotlin/io/papermc/paperweight/core/tasks/patching/RebuildFilePatches.kt
Show resolved
Hide resolved
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This pull request updates diffpatch to the currently latest version and migrates previous inputs and outputs to use the Multi/Single Input/Output interfaces
Everything was tested locally and using a dev bundle and no regressions nor changes in patch output have been noticed. Also was tested in production in a fork of Paperweight which is used by some projects.
The reasoning for this update is to keep up-to-date with the latest improvements in the library (such as fixing ghost patches) and also the new version of diffpatch allows for outputting rejected hunks as patches which opens a way to a new functionality for paperweight