Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: New approach for creating custom command for impact analysis #130

Merged

Conversation

Evleaps
Copy link
Contributor

@Evleaps Evleaps commented Apr 5, 2022

Hello! My name is Roman.
You can write me:
Twiter: @Evleaps
WhatApp: +79056609998

Description

Creating of new gradle task with impact analysis is qiute complex task.
Need to create buildSrc and custom plugin, but it might be not trivial knowledge for general people. This mean that people can decline using this library due to complexety of extention. Also, using buildSrc quite complex, developers can make some mistakes which will rebuild all dependencies. Hence, a build time might be increased.

Problem:

Add new gradle command quite complex.

Solution

Share interface to developers. They can add customTasks in configuration without buildSrc.

  • Interface: "AffectedModuleTaskType"
  • New configuration field: "customTasks"
  • small code refactoring

NOTE

Please, start your review from readme.md

@CLAassistant
Copy link

CLAassistant commented Apr 5, 2022

CLA assistant check
All committers have signed the CLA.

README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
@Evleaps Evleaps marked this pull request as draft April 17, 2022 21:09
@Evleaps Evleaps marked this pull request as ready for review April 20, 2022 20:11
@codecov
Copy link

codecov bot commented May 3, 2022

Codecov Report

Merging #130 (28958b5) into main (581fe1d) will increase coverage by 3.91%.
The diff coverage is 73.68%.

@@             Coverage Diff              @@
##               main     #130      +/-   ##
============================================
+ Coverage     49.78%   53.69%   +3.91%     
- Complexity       58       68      +10     
============================================
  Files            12       13       +1     
  Lines           462      514      +52     
  Branches         96       97       +1     
============================================
+ Hits            230      276      +46     
- Misses          207      212       +5     
- Partials         25       26       +1     
Impacted Files Coverage Δ
...ctedmoduledetector/AffectedModuleDetectorPlugin.kt 51.06% <63.23%> (+10.76%) ⬆️
...ectedmoduledetector/AffectedModuleConfiguration.kt 100.00% <100.00%> (ø)
...ffectedmoduledetector/AffectedTestConfiguration.kt 100.00% <100.00%> (ø)
...dropbox/affectedmoduledetector/InternalTaskType.kt 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 581fe1d...28958b5. Read the comment docs.

@joshafeinberg joshafeinberg merged commit 6c2b902 into dropbox:main May 5, 2022
* @see CustomTask - Implementation class
* @see AffectedModuleDetectorPlugin - gradle plugin
*/
var customTasks = emptySet<AffectedModuleConfiguration.CustomTask>()
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should better use DomainObject APIs. I've created #161 for tracking that.

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.

4 participants