Simply processResources logic & make it compatible with future versions of Gradle #69
No reviewers
Labels
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: Steven/fabric-example-mod#69
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "master"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
When the processResources task is currently run, it uses deprecated Gradle features. Running "gradle clean build --warning-mode all" on this example project should output a message along the lines of "Copying or archiving duplicate paths with the default duplicates strategy has been deprecated. This is scheduled to be removed in Gradle 7.0.". This is due to the build script currently including all files twice. Gradle includes the resources directory by default, and the build script includes it again with the "from" block. This PR simply uses "filesMatching" to instead select the relevant files from the already included resources directory, leaving all other resources unmodified but still included in the output of the task. This also reduces the amount of repetition in the script, and helps with reducing human error (e.g. changing only one "from" block to the new desired behaviour).
This PR also includes an edit to the .gitignore to ignore commonly generated Mac OS junk files. This is optional, but would be a huge quality of life improvement for anyone developing on Mac OS, as the first thing I do when starting a new project is always to add this to the .gitignore. Example: Just from the small changes I've made to the build script alone, I've generated 4 .DS_Store files, which would clutter up this PR if I included them.
Looks good, I will test before merging when I get a chance