Skip to content

Commit

Permalink
[#3699] Small optimisations
Browse files Browse the repository at this point in the history
  • Loading branch information
api-from-the-ion committed Nov 17, 2023
1 parent e9dd506 commit d4c1f7f
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ public Builder mavenConfig(@Nullable Path mavenConfig) {
if (mavenConfig != null && mavenConfig.toFile().exists()) {
try {
String mavenConfigText = new String(Files.readAllBytes(mavenConfig));
Matcher matcher = Pattern.compile("(?:$|\\s)-P\\s+([^\\s]+)").matcher(mavenConfigText);
Matcher matcher = Pattern.compile("(?:$|\\s)-P\\s+(\\S+)").matcher(mavenConfigText);
if (matcher.find()) {
String[] profiles = matcher.group(1).split(",");
return activeProfiles(profiles);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -853,7 +853,6 @@ void mirrorsAndAuth() throws IOException {
var password = "password";
try (MockWebServer mockRepo = new MockWebServer()) {
mockRepo.setDispatcher(new Dispatcher() {
@SuppressWarnings("NullableProblems")
@Override
public MockResponse dispatch(RecordedRequest request) {
MockResponse resp = new MockResponse();
Expand Down

0 comments on commit d4c1f7f

Please sign in to comment.