Skip to content

Commit

Permalink
added resources to jar build - relates to github #1660
Browse files Browse the repository at this point in the history
  • Loading branch information
dghgit committed Dec 22, 2024
1 parent d3f5333 commit fab2677
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions jmail/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ sourceSets {
java {
srcDirs = ['build/src/main/java']
}
resources {
srcDirs = ['build/src/main/resources']
}
}

java9 {
Expand Down Expand Up @@ -39,13 +42,14 @@ evaluationDependsOn(":pkix")

task copyTask(type: Copy) {
duplicatesStrategy = 'include'
from '../mail/src/main/java'
from 'src/main/java'
into 'build/src/main/java'
from '../mail/src/main'
from 'src/main'
into 'build/src/main'
filter { String line -> (line.contains('javax.mail') || line.contains('javax.activation')) ? line.replace('javax.mail', 'jakarta.mail').replace('javax.activation', 'jakarta.activation') : line }
}

compileJava.dependsOn(copyTask)
processResources.dependsOn(copyTask)


compileJava {
Expand Down

0 comments on commit fab2677

Please sign in to comment.