Skip to content

Conversation

@jonapoul
Copy link
Contributor

@jonapoul jonapoul commented May 18, 2025

Previously there was the ProjectTarget enum to identify a project type based on the applied plugins, which is nice but I wanted to add some extra logic beyond just the plugin IDs for selecting these - plus the option for different node types.

So I've mapped it into a more generic config option for both graph types, along with typealiases to make it a bit easier to work with.

Also added the same for dependency node types - with a null default implementation alongside an optional implementation which does a dumb check on the hash of the dependency group to come up with a common colour.

❓ Side question ❓

I've been poking around the repo trying to get it to work nicely with Gradle's configuration cache - I think it's doable but it will probably mean a significant project rework. Would you rather I did that separately on my fork?

@jonapoul jonapoul marked this pull request as ready for review May 18, 2025 12:45
@vanniktech
Copy link
Owner

I'll take a look later today!

Copy link
Owner

@vanniktech vanniktech left a comment

Choose a reason for hiding this comment

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

This looks really good. Regarding configuration cache, I'd love to have it but I have limited time available and can't dedicate much time here. I will always review PRs though!

when {
dependency.moduleName.contains("x") -> BasicNodeType("#ABC123", Shape.EGG)
dependency.moduleName.contains("k") -> BasicNodeType("#DEF789", Shape.POINT)
// !dependency.moduleGroup.contains("kotlin") -> BasicNodeType("#000000", Shape.OCTAGON)
Copy link
Owner

Choose a reason for hiding this comment

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

what about this one?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah yeah, forgot about that. Removed

@jonapoul
Copy link
Contributor Author

Awesome, I'll have a mess around and see what I can come up with!

@vanniktech vanniktech merged commit 5f66c58 into vanniktech:master May 20, 2025
1 check passed
@jonapoul jonapoul deleted the project-mapper branch May 20, 2025 10:25
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.

2 participants