Skip to content

Commit f8df4db

Browse files
authored
Merge pull request #17 from davidnavas/master
Exclude non-jar files
2 parents 1ba53c6 + 0a55500 commit f8df4db

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/main/groovy/com/github/mrsarm/jshell/plugin/JShellPlugin.groovy

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,10 @@ class JShellPlugin implements Plugin<Project> {
6363
'the following paths from project configurations: {}', depsPaths)
6464
pathSet.addAll(depsPaths)
6565
}
66+
67+
// Exclude non-directory / non-jar files that jshell doesn't deal with
68+
pathSet = pathSet.findAll{ new File(it.toString()).isDirectory() || it.toString().endsWith('.jar') }
69+
6670
def path = pathSet.join(System.getProperty("path.separator"))
6771
jshellTask.logger.info(":jshell executing with --class-path {}", path)
6872
shellArgs += [

0 commit comments

Comments
 (0)