-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Configurable gradle configurations #3034
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
Changes from 10 commits
878b349
d8241eb
ea8ac3c
fefa84e
ed974c4
d723500
0cfd54e
fd0c3f7
9f53ad7
58ad2ed
37c1480
539f08c
3596a4f
587e258
4953616
00b3eb1
bf13c92
711e382
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -21,6 +21,7 @@ | |
| import org.gradle.api.Action; | ||
| import org.gradle.api.Project; | ||
| import org.gradle.api.model.ObjectFactory; | ||
| import org.gradle.api.plugins.JavaPlugin; | ||
| import org.gradle.api.provider.ListProperty; | ||
| import org.gradle.api.provider.Property; | ||
| import org.gradle.api.tasks.Input; | ||
|
|
@@ -94,6 +95,7 @@ public class JibExtension { | |
| private final SkaffoldParameters skaffold; | ||
| private final Property<Boolean> allowInsecureRegistries; | ||
| private final Property<String> containerizingMode; | ||
| private final Property<String> configurationName; | ||
| private final ListProperty<ExtensionParameters> pluginExtensions; | ||
| private final ExtensionParametersSpec extensionParametersSpec; | ||
|
|
||
|
|
@@ -118,6 +120,15 @@ public JibExtension(Project project) { | |
| objectFactory.newInstance(ExtensionParametersSpec.class, pluginExtensions); | ||
| allowInsecureRegistries = objectFactory.property(Boolean.class); | ||
| containerizingMode = objectFactory.property(String.class); | ||
| configurationName = | ||
| objectFactory | ||
| .property(String.class) | ||
| .convention( | ||
| project.provider( | ||
| () -> | ||
| System.getProperty( | ||
| PropertyNames.CONFIGURATION_NAME, | ||
| JavaPlugin.RUNTIME_CLASSPATH_CONFIGURATION_NAME))); | ||
cromefire marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| // Sets defaults. | ||
| allowInsecureRegistries.set(DEFAULT_ALLOW_INSECURE_REGISTIRIES); | ||
|
|
@@ -221,6 +232,12 @@ public String getContainerizingMode() { | |
| return property != null ? property : containerizingMode.get(); | ||
| } | ||
|
|
||
| @Input | ||
| @Optional | ||
| public Property<String> getConfigurationName() { | ||
| return configurationName; | ||
|
||
| } | ||
|
|
||
| @Nested | ||
| @Optional | ||
| public ListProperty<ExtensionParameters> getPluginExtensions() { | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.