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

GH-135: Implement ability to only include direct dependencies #139

Merged
merged 2 commits into from
Mar 23, 2024

Conversation

ascopes
Copy link
Owner

@ascopes ascopes commented Mar 22, 2024

A component that makes up a small part of the overall solution for GH-135, by providing the initial ability to not include transitive dependencies implicitly, only directly specified ones.

This is achieved via a new parameter dependencyResolutionDepth which will be set to TRANSITIVE by default to exhibit the current resolution behaviour. It can optionally be set to DIRECT instead to allow only adding explicitly included dependencies to the protopath.

The change will be complimented in a future set of PRs with the ability to add dependencies without making them visible to the Java compiler, and the ability to disable reading the Java classpath dependencies at all to enable more control over how the dependency mechanism works.

@ascopes ascopes added the new feature A new user-facing feature. label Mar 22, 2024
@ascopes ascopes self-assigned this Mar 22, 2024
Copy link

codecov bot commented Mar 22, 2024

Codecov Report

Attention: Patch coverage is 77.27273% with 5 lines in your changes are missing coverage. Please review.

Project coverage is 82.49%. Comparing base (8de0163) to head (53137d8).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #139      +/-   ##
==========================================
- Coverage   82.67%   82.49%   -0.17%     
==========================================
  Files          24       25       +1     
  Lines         819      828       +9     
  Branches       54       55       +1     
==========================================
+ Hits          677      683       +6     
- Misses        122      124       +2     
- Partials       20       21       +1     
Files Coverage Δ
...opes/protobufmavenplugin/AbstractGenerateMojo.java 82.26% <100.00%> (+0.30%) ⬆️
...enplugin/dependency/DependencyResolutionDepth.java 100.00% <100.00%> (ø)
...tobufmavenplugin/dependency/JvmPluginResolver.java 85.42% <100.00%> (ø)
...avenplugin/dependency/PlatformArtifactFactory.java 100.00% <ø> (ø)
...tobufmavenplugin/generate/SourceCodeGenerator.java 90.70% <100.00%> (+0.23%) ⬆️
...plugin/dependency/MavenDependencyPathResolver.java 80.56% <58.34%> (-7.32%) ⬇️

@ascopes ascopes marked this pull request as draft March 22, 2024 11:37
@ascopes ascopes marked this pull request as ready for review March 23, 2024 08:25
@ascopes ascopes merged commit 1eb8711 into main Mar 23, 2024
13 of 15 checks passed
@ascopes ascopes deleted the task/GH-135-exclude-transitive-dependencies branch March 23, 2024 08:25
@ascopes ascopes linked an issue Apr 7, 2024 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new feature A new user-facing feature.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature request: Manually control the compilation import-path
1 participant