Skip to content

Commit 594ff69

Browse files
authored
Merge pull request #14696 from jdaugherty/7.0.x
Automate grailsw distribution
2 parents cf0cc75 + 2fa4841 commit 594ff69

File tree

15 files changed

+212
-769
lines changed

15 files changed

+212
-769
lines changed

grails-profiles/.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
*/skeleton/grailsw
2+
*/skeleton/grailsw.bat
3+
*/skeleton/grails-wrapper.jar

grails-profiles/base/build.gradle

+20
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,26 @@ dependencies {
3434
profileRuntimeApi 'org.apache.groovy:groovy-jmx' // stop script uses GroovyMBean
3535
}
3636

37+
TaskProvider<Copy> copyWrapper = tasks.register('copyGrailsWrapperScripts', Copy)
38+
copyWrapper.configure { Copy copy ->
39+
Project wrapperProject = rootProject.project(':grails-wrapper')
40+
copy.dependsOn(wrapperProject.tasks.named('installDist'))
41+
copy.from(wrapperProject.layout.buildDirectory.dir('install/grails-wrapper'))
42+
copy.into(project.layout.projectDirectory.dir('skeleton'))
43+
}
44+
45+
tasks.named('sourcesProfileJar').configure {
46+
it.dependsOn(copyWrapper)
47+
}
48+
49+
tasks.named('processProfileResources').configure {
50+
it.dependsOn(copyWrapper)
51+
}
52+
53+
tasks.named('compileProfile').configure {
54+
it.dependsOn(copyWrapper)
55+
}
56+
3757
apply {
3858
from rootProject.layout.projectDirectory.file('gradle/publish-config.gradle')
3959
}
-5.61 KB
Binary file not shown.

grails-profiles/base/skeleton/grailsw

-152
This file was deleted.

grails-profiles/base/skeleton/grailsw.bat

-89
This file was deleted.

grails-profiles/profile/build.gradle

+20
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,26 @@ dependencies {
3333
profileRuntimeOnly project(':grails-profiles-base')
3434
}
3535

36+
TaskProvider<Copy> copyWrapper = tasks.register('copyGrailsWrapperScripts', Copy)
37+
copyWrapper.configure { Copy copy ->
38+
Project wrapperProject = rootProject.project(':grails-wrapper')
39+
copy.dependsOn(wrapperProject.tasks.named('installDist'))
40+
copy.from(wrapperProject.layout.buildDirectory.dir('install/grails-wrapper'))
41+
copy.into(project.layout.projectDirectory.dir('skeleton'))
42+
}
43+
44+
tasks.named('sourcesProfileJar').configure {
45+
it.dependsOn(copyWrapper)
46+
}
47+
48+
tasks.named('processProfileResources').configure {
49+
it.dependsOn(copyWrapper)
50+
}
51+
52+
tasks.named('compileProfile').configure {
53+
it.dependsOn(copyWrapper)
54+
}
55+
3656
apply {
3757
from rootProject.layout.projectDirectory.file('gradle/publish-config.gradle')
3858
}
Binary file not shown.

0 commit comments

Comments
 (0)