Create tasks for debug variant which are not run by default #139
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.
Goal
Tasks were not created for the debug buildType when
bugsnag.uploadDebugBuildMappings
was set to false. This means it's not possible to manually invoke the mapping file upload task for the debug buildType.For example,
./gradlew uploadBugsnagJavaExample-debugMapping
would be unsuccessful as the task does not exist in the project, whereas./gradlew uploadBugsnagJavaExample-releaseMapping
would be successful.Our aim is to alter the plugin so that these debug tasks are created, but not run automatically. This is because in most scenarios, debug mapping files are not required and can slow down the build process.
Changeset
This changeset alters the plugin so that tasks are created regardless of build type. A dependency between tasks is only added if
bugsnag.uploadDebugBuildMappings
is true, meaning that only non-debug tasks are run automatically.Tests
The existing mazerunner scenarios were run, to verify that debug mappings are not uploaded automatically. Additionally a debug mapping upload task was invoked manually in an example project where the artefact was installed.