Skip to content
This repository was archived by the owner on Sep 1, 2025. It is now read-only.

Commit f686fbc

Browse files
committed
Bump groovy 4 + nextflow 24.01.x
Signed-off-by: Paolo Di Tommaso <[email protected]>
1 parent 2faf688 commit f686fbc

File tree

8 files changed

+40
-14
lines changed

8 files changed

+40
-14
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
strategy:
1818
fail-fast: false
1919
matrix:
20-
java_version: [8, 11]
20+
java_version: [11, 21]
2121

2222
steps:
2323
- name: Environment

Makefile

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ mm =
88
endif
99

1010
clean:
11+
rm -rf .nextflow*
12+
rm -rf work
13+
rm -rf build
14+
rm -rf plugins/*/build
1115
./gradlew clean
1216

1317
compile:
@@ -44,6 +48,9 @@ else
4448
./gradlew ${mm}test --tests ${class}
4549
endif
4650

51+
assemble:
52+
./gradlew assemble
53+
4754
#
4855
# generate build zips under build/plugins
4956
# you can install the plugin copying manually these files to $HOME/.nextflow/plugins
@@ -62,4 +69,4 @@ upload-plugins:
6269
./gradlew plugins:upload
6370

6471
publish-index:
65-
./gradlew plugins:publishIndex
72+
./gradlew plugins:publishIndex

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ To build and test the plugin during development, configure a local Nextflow buil
7777

7878
3. Compile the plugin alongside the Nextflow code:
7979
```bash
80-
make compile
80+
make assemble
8181
```
8282

8383
4. Run Nextflow with the plugin, using `./launch.sh` as a drop-in replacement for the `nextflow` command, and adding the option `-plugins nf-hello` to load the plugin:
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3.3-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists

plugins/nf-hello/build.gradle

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ sourceSets {
5050
}
5151

5252
ext{
53-
nextflowVersion = '23.04.0'
53+
nextflowVersion = '24.01.0-edge'
5454
}
5555

5656
dependencies {
@@ -61,14 +61,14 @@ dependencies {
6161
// add here plugins depepencies
6262

6363
// test configuration
64-
testImplementation "org.codehaus.groovy:groovy:3.0.17"
65-
testImplementation "org.codehaus.groovy:groovy-nio:3.0.17"
64+
testImplementation "org.apache.groovy:groovy:4.0.18"
65+
testImplementation "org.apache.groovy:groovy-nio:4.0.18"
6666
testImplementation "io.nextflow:nextflow:$nextflowVersion"
67-
testImplementation ("org.codehaus.groovy:groovy-test:3.0.17") { exclude group: 'org.codehaus.groovy' }
67+
testImplementation ("org.apache.groovy:groovy-test:4.0.18") { exclude group: 'org.apache.groovy' }
6868
testImplementation ("cglib:cglib-nodep:3.3.0")
6969
testImplementation ("org.objenesis:objenesis:3.1")
70-
testImplementation ("org.spockframework:spock-core:2.2-groovy-3.0") { exclude group: 'org.codehaus.groovy'; exclude group: 'net.bytebuddy' }
71-
testImplementation ('org.spockframework:spock-junit4:2.2-groovy-3.0') { exclude group: 'org.codehaus.groovy'; exclude group: 'net.bytebuddy' }
70+
testImplementation ("org.spockframework:spock-core:2.3-groovy-4.0") { exclude group: 'org.apache.groovy'; exclude group: 'net.bytebuddy' }
71+
testImplementation ('org.spockframework:spock-junit4:2.3-groovy-4.0') { exclude group: 'org.apache.groovy'; exclude group: 'net.bytebuddy' }
7272
testImplementation ('com.google.jimfs:jimfs:1.1')
7373

7474
testImplementation(testFixtures("io.nextflow:nextflow:$nextflowVersion"))
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Manifest-Version: 1.0
22
Plugin-Id: nf-hello
3-
Plugin-Version: 0.4.0
3+
Plugin-Version: 0.5.0
44
Plugin-Class: nextflow.hello.HelloPlugin
55
Plugin-Provider: nextflow
6-
Plugin-Requires: >=22.10.0
6+
Plugin-Requires: >=24.01.0-edge

plugins/nf-hello/src/test/nextflow/hello/HelloDslTest.groovy

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
package nextflow.hello
22

3+
import java.nio.file.Files
4+
import java.util.jar.Manifest
5+
36
import nextflow.Channel
47
import nextflow.plugin.Plugins
58
import nextflow.plugin.TestPluginDescriptorFinder
@@ -35,9 +38,18 @@ class HelloDslTest extends Dsl2Spec{
3538
@Override
3639
protected PluginDescriptorFinder createPluginDescriptorFinder() {
3740
return new TestPluginDescriptorFinder(){
41+
3842
@Override
39-
protected Path getManifestPath(Path pluginPath) {
40-
return pluginPath.resolve('build/resources/main/META-INF/MANIFEST.MF')
43+
protected Manifest readManifestFromDirectory(Path pluginPath) {
44+
if( !Files.isDirectory(pluginPath) )
45+
return null
46+
47+
final manifestPath = pluginPath.resolve('build/resources/main/META-INF/MANIFEST.MF')
48+
if( !Files.exists(manifestPath) )
49+
return null
50+
51+
final input = Files.newInputStream(manifestPath)
52+
return new Manifest(input)
4153
}
4254
}
4355
}

settings.gradle

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,13 @@
1414
* limitations under the License.
1515
*/
1616

17+
plugins {
18+
// required to download the toolchain (jdk) from a remote repository
19+
// https://github.com/gradle/foojay-toolchains
20+
// https://docs.gradle.org/current/userguide/toolchains.html#sub:download_repositories
21+
id("org.gradle.toolchains.foojay-resolver-convention") version "0.7.0"
22+
}
23+
1724
rootProject.name = 'nf-hello'
1825
include('plugins')
1926
include('plugins:nf-hello')

0 commit comments

Comments
 (0)