Skip to content

Commit 2fffebc

Browse files
author
elasticsearchmachine
committed
[CI] Auto commit changes from spotless
1 parent cd6f002 commit 2fffebc

File tree

2 files changed

+6
-8
lines changed

2 files changed

+6
-8
lines changed

build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/transport/GenerateTransportVersionDefinitionTask.java

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
import org.gradle.process.ExecOperations;
2929
import org.gradle.process.ExecResult;
3030

31-
import javax.inject.Inject;
3231
import java.io.ByteArrayOutputStream;
3332
import java.io.IOException;
3433
import java.nio.charset.StandardCharsets;
@@ -42,6 +41,8 @@
4241
import java.util.function.BiFunction;
4342
import java.util.function.Function;
4443

44+
import javax.inject.Inject;
45+
4546
import static org.elasticsearch.gradle.internal.transport.TransportVersionUtils.IdComponents.PATCH;
4647
import static org.elasticsearch.gradle.internal.transport.TransportVersionUtils.IdComponents.SERVER;
4748
import static org.elasticsearch.gradle.internal.transport.TransportVersionUtils.IdComponents.SUBSIDIARY;
@@ -61,14 +62,13 @@
6162
*/
6263
public abstract class GenerateTransportVersionDefinitionTask extends DefaultTask {
6364

64-
6565
/**
6666
* Specifies the directory in which contains all TransportVersionSet data files.
6767
*
6868
* @return
6969
*/
7070
@InputDirectory
71-
// @Optional
71+
// @Optional
7272
@PathSensitive(PathSensitivity.RELATIVE)
7373
public abstract DirectoryProperty getResourcesDirectory();// The plugin should always set this, not optional
7474

@@ -79,7 +79,7 @@ public abstract class GenerateTransportVersionDefinitionTask extends DefaultTask
7979
* Used to set the name of the TransportVersionSet for which a data file will be generated.
8080
*/
8181
@Input
82-
// @Optional
82+
// @Optional
8383
@Option(option = "name", description = "TBD")
8484
public abstract Property<String> getTransportVersionName(); // The plugin should always set this, not optional
8585

@@ -112,9 +112,7 @@ public void generateTransportVersionData() throws IOException {
112112
Path resourcesDir = Objects.requireNonNull(getResourcesDirectory().getAsFile().get()).toPath();
113113
String name = getTransportVersionName().isPresent() ? getTransportVersionName().get() : findLocalTransportVersionName();
114114
Set<String> targetMinorVersions = new HashSet<>(
115-
getBranches().isPresent()
116-
? new HashSet<>(getBranches().get())
117-
: findTargetMinorVersions()
115+
getBranches().isPresent() ? new HashSet<>(getBranches().get()) : findTargetMinorVersions()
118116
);
119117

120118
List<TransportVersionId> ids = new ArrayList<>();

build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/transport/TransportVersionUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
package org.elasticsearch.gradle.internal.transport;
1111

1212
import com.google.common.collect.Comparators;
13+
1314
import org.gradle.api.GradleException;
1415
import org.gradle.api.Project;
1516
import org.gradle.api.attributes.Attribute;
@@ -241,5 +242,4 @@ static void addTransportVersionReferencesAttribute(AttributeContainer attributes
241242
attributes.attribute(TransportVersionUtils.TRANSPORT_VERSION_REFERENCES_ATTRIBUTE, true);
242243
}
243244

244-
245245
}

0 commit comments

Comments
 (0)