@@ -63,6 +63,7 @@ subprojects {
63
63
* Creates plugin zip and json meta file in the plugin `build/libs` directory
64
64
*/
65
65
task makeZip(type : Jar ) {
66
+ group ' nextflow'
66
67
into(' classes' ) { with jar }
67
68
into(' lib' ) { from configurations. runtimeClasspath }
68
69
manifest. from file(' src/resources/META-INF/MANIFEST.MF' )
@@ -84,36 +85,45 @@ subprojects {
84
85
}
85
86
""" . stripIndent()
86
87
}
88
+ outputs. file(" $buildDir /libs/${ project.name} -${ project.version} .zip" )
87
89
}
88
90
89
91
/*
90
92
* Copy the plugin dependencies in the subproject `build/target/libs` directory
91
93
*/
92
94
task copyPluginLibs(type : Sync ) {
95
+ group ' nextflow'
93
96
from configurations. runtimeClasspath
94
97
into ' build/target/libs'
95
98
}
96
99
97
100
/*
98
101
* Copy the plugin in the project root build/plugins directory
99
102
*/
100
- task copyPluginZip(type : Copy ) {
101
- from makeZip
103
+ task copyPluginZip(type : Copy , dependsOn : project. tasks. findByName(' makeZip' )) {
104
+ group ' nextflow'
105
+ from project. tasks. findByName(' makeZip' )
102
106
into " $rootProject . buildDir /plugins"
107
+ outputs. file(" $rootProject . buildDir /plugins/${ project.name} -${ project.version} .zip" )
108
+ doLast {
109
+ ant. unzip(
110
+ src : " $rootProject . buildDir /plugins/${ project.name} -${ project.version} .zip" ,
111
+ dest : " $rootProject . buildDir /plugins/${ project.name} -${ project.version} "
112
+ )
113
+ }
103
114
}
104
115
105
116
/*
106
- * Unzip the plugin artifact in the project root build/plugins directory
107
- */
108
- task unzipPlugin(type : Copy , dependsOn : copyPluginZip) {
109
- from zipTree(" $rootProject . buildDir /plugins/${ project.name} -${ project.version} .zip" )
110
- into " $rootProject . buildDir /plugins/${ project.name} -${ project.version} "
111
- }
117
+ * "install" the plugin the project root build/plugins directory
118
+ */
119
+ project. parent. tasks. getByName(" assemble" ). dependsOn << copyPluginZip
120
+
112
121
113
122
/*
114
123
* Upload the plugin zip & json meta file to the corresponding GitHub repo
115
124
*/
116
125
task uploadPlugin(type : GithubUploader , dependsOn : makeZip) {
126
+ group ' nextflow'
117
127
assets = providers. provider {[" $buildDir /libs/${ project.name} -${ project.version} .zip" ,
118
128
" $buildDir /libs/${ project.name} -${ project.version} -meta.json" ]}
119
129
release = providers. provider { project. version }
@@ -173,7 +183,7 @@ classes.dependsOn subprojects.copyPluginLibs
173
183
/*
174
184
* "install" the plugin the project root build/plugins directory
175
185
*/
176
- assemble. dependsOn subprojects . unzipPlugin
186
+ project . parent . tasks . getByName( " assemble" ) . dependsOn << assemble
177
187
178
188
/*
179
189
* Merge and publish the plugins index file
0 commit comments