You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@groovy.apache.org by pa...@apache.org on 2025/08/25 09:51:36 UTC

(groovy) branch master updated: merge upstream improvement

This is an automated email from the ASF dual-hosted git repository.

paulk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/groovy.git


The following commit(s) were added to refs/heads/master by this push:
     new 1cee744c5c merge upstream improvement
1cee744c5c is described below

commit 1cee744c5cd3d45367e95a62b014d600d6186d06
Author: Paul King <pa...@asert.com.au>
AuthorDate: Mon Aug 25 19:51:28 2025 +1000

    merge upstream improvement
---
 .../groovy/org/apache/groovy/groovysh/jline/GroovyPosixCommands.java  | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/subprojects/groovy-groovysh/src/main/groovy/org/apache/groovy/groovysh/jline/GroovyPosixCommands.java b/subprojects/groovy-groovysh/src/main/groovy/org/apache/groovy/groovysh/jline/GroovyPosixCommands.java
index cb7aa2c25c..5ee835ddeb 100644
--- a/subprojects/groovy-groovysh/src/main/groovy/org/apache/groovy/groovysh/jline/GroovyPosixCommands.java
+++ b/subprojects/groovy-groovysh/src/main/groovy/org/apache/groovy/groovysh/jline/GroovyPosixCommands.java
@@ -924,7 +924,7 @@ public class GroovyPosixCommands extends PosixCommands {
             if ("-".equals(arg)) {
                 sources.add(new Source.StdInSource(context.in()));
             } else {
-                sources.addAll(maybeExpandGlob(context, arg)
+                maybeExpandGlob(context, arg)
                     .map(p -> {
                         try {
                             return new Source.URLSource(p.toUri().toURL(), p.toString());
@@ -932,7 +932,7 @@ public class GroovyPosixCommands extends PosixCommands {
                             throw new RuntimeException(e);
                         }
                     })
-                    .collect(Collectors.toList()));
+                    .forEach(sources::add);
             }
         }