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

#8 Support multiple binding files #9

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

lkoe
Copy link

@lkoe lkoe commented May 19, 2021

I've switched to FileCollection for the extension/task property and added a convenience method to the extension so users won't necessarily have to deal with the FileCollection.from() syntax.

This appeared to me as the most "natural" approach, opposed to having a ListProperty<File> (inconsistent with the other properties) oder even ListProperty<RegularFile> (a bit painful to handle, layout.file() syntax being not commonly known/understood by users).

~~ One thing where I wasn't 100% sure was how to configure the FileCollection task property from the extension property. Here the convention approach is not available and there aren't any super clear docs/examples how to do this. But it seems to work alright the way it's done here. ~~

Edit: after being a bit more versed in the approach to lazy configuration of gradle tasks, I'd argue that the approach taken in the plugin is not 100% idiomatic. Typically one would not refer to the extension properties in the task implementation.
Rather there the task properties should be "unbiased" and preferable empty, except obvious defaults.
The plugin implementation should instead be responsible of connecting the extension properties to the task properties.

However, in this PR I've gone along with the approach taken here.

@lkoe lkoe force-pushed the 8-support-multiple-bindings branch from 52b5f97 to e9a0718 Compare August 16, 2023 13:10
@sreich
Copy link

sreich commented Sep 14, 2023

Hello, bumping because I'm interested in seeing this PR merged and need multiple binding files with this plugin. Are there updates on this?

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.

None yet

2 participants