@@ -33,7 +33,7 @@ applyv25patches() {
3333 ;;
3434 esac
3535 # # TODO: document in migration guide to 25
36- patchImports ' import com.fasterxml.jackson.core.type.TypeReference;' ' import tools.jackson.core.type.TypeReference;'
36+ patchImports ' import com.fasterxml.jackson.core.type.TypeReference;' ' import tools.jackson.core.type.TypeReference;'
3737
3838 diff_=` git diff $D $F | egrep ' ^[+-]' `
3939 [ -z " $TEST " -a -n " $diff_ " ] && echo " " && warn " Patched sources\n" && dim " ====== BEGIN ======\n\n$diff_ \n====== END ======"
@@ -64,15 +64,19 @@ cleanAfterBumpingVersions() {
6464 [ -z " $NOCURRENT " ] && [ ! -d target ] && return
6565 # # vaadin:clean-frontend is not enough it needs to clean target too
6666 # # note that archetype-spring (and maybe others) needs the production profile to have vaadin plugin available
67- grep -q " flow-maven-plugin" pom.xml && mplugin=flow || mplugin=vaadin
68- runCmd " Cleaning project after version bump" " mvn clean $mplugin :clean-frontend -Pproduction"
67+ for i in ` getPomFiles` ; do
68+ local P
69+ grep -q " vaadin-maven-plugin" $i && P=vaadin
70+ grep -q " flow-maven-plugin" $i && P=flow
71+ [ -z " $P " ] || runCmd " Cleaning project after version bump" " mvn clean $P :clean-frontend -Pproduction -f $i "
72+ done
6973}
7074
7175# # Find all java class files that extend AppLayout and have afterNavigation() method, then update them to implement AfterNavigationObserver
7276# # This break change is in https://github.com/vaadin/flow-components/issues/5449
7377# # TODO: needs to be documented in vaadin migration guide to 25 and updated in starter repos
7478updateAppLayoutAfterNavigation () {
75- find src -name " *.java" -exec grep -l " extends AppLayout" {} | xargs grep -L " extends AppLayoutElement" | while read file; do
79+ find . -name " *.java" -exec grep -l " extends AppLayout" {} + | xargs grep -L " extends AppLayoutElement" | while read file; do
7680 # Check if the file contains afterNavigation method
7781 if grep -q " afterNavigation()" " $file " ; then
7882 [ -z " $TEST " ] && warn " updating afterNavigation method in $file " || cmd " ## updating afterNavigation method in $file "
@@ -98,7 +102,7 @@ updateAppLayoutAfterNavigation() {
98102# # TODO: needs to be documented in vaadin migration guide to 25
99103updateSpringBootApplication () {
100104 # Find the Application class with @SpringBootApplication annotation
101- local app_file=$( find src -name " *.java" -exec grep -l " @SpringBootApplication" {} +)
105+ local app_file=$( find . -name " *.java" -exec grep -l " @SpringBootApplication" {} +)
102106
103107 [ -z " $app_file " ] && return 0
104108
0 commit comments