Skip to content

Commit f9c7d5e

Browse files
committed
fix fastfile for build gradle kts
Signed-off-by: alperozturk <[email protected]>
1 parent b595eed commit f9c7d5e

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

fastlane/Fastfile

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ lane :RC_releasePhase1 do
5757
enableLogger()
5858
end
5959

60-
desc "Release phase 2 for RC: checks, tag, upload gplay to playstore with values from build.gradle"
60+
desc "Release phase 2 for RC: checks, tag, upload gplay to playstore with values from build.gradle.kts"
6161
lane :RC_releasePhase2 do |options|
6262
checkReleaseRequirements_RC()
6363
info = androidVersion
@@ -78,7 +78,7 @@ lane :Final_releasePhase1 do
7878
makeReleases()
7979
end
8080

81-
desc "Release phase 2 for FINAL: checks, tag, upload gplay to playstore with values from build.gradle"
81+
desc "Release phase 2 for FINAL: checks, tag, upload gplay to playstore with values from build.gradle.kts"
8282
lane :Final_releasePhase2 do |options|
8383
checkReleaseRequirements_Final()
8484
info = androidVersion
@@ -214,10 +214,10 @@ private_lane :androidVersion do
214214
text = f.read
215215

216216
# everything between Document and Authors
217-
major = text.match(/def versionMajor = ([0-9]*)$/)
218-
minor = text.match(/def versionMinor = ([0-9]*)$/)
219-
patch = text.match(/def versionPatch = ([0-9]*)$/)
220-
build = text.match(/def versionBuild = ([0-9]*).*$/)
217+
major = text.match(/val versionMajor\s*=\s*([0-9]*)/)
218+
minor = text.match(/val versionMinor\s*=\s*([0-9]*)/)
219+
patch = text.match(/val versionPatch\s*=\s*([0-9]*)/)
220+
build = text.match(/val versionBuild\s*=\s*([0-9]*)/)
221221

222222
majorInt = major[1].to_i
223223
minorInt = minor[1].to_i
@@ -261,12 +261,12 @@ end
261261

262262
desc "check if library is set correctly"
263263
private_lane :checkLibrary_RC do
264-
sh(" if [ $(egrep 'androidLibraryVersion.*master.*' ../build.gradle -c) -eq 1 ] ; then echo 'Library is set to master tag; aborting!' ; exit 1 ; fi")
264+
sh(" if [ $(egrep 'androidLibraryVersion.*master.*' ../build.gradle.kts -c) -eq 1 ] ; then echo 'Library is set to master tag; aborting!' ; exit 1 ; fi")
265265
end
266266

267267
desc "check if library is set correctly: must NOT contain master nor rc"
268268
private_lane :checkLibrary_Final do
269-
sh(" if [ $(grep 'androidLibraryVersion' ../build.gradle | egrep 'master|rc' -c) -eq 1 ] ; then echo 'Library is still set to rc tag; aborting!' ; exit 1 ; fi")
269+
sh(" if [ $(grep 'androidLibraryVersion' ../build.gradle.kts | egrep 'master|rc' -c) -eq 1 ] ; then echo 'Library is still set to rc tag; aborting!' ; exit 1 ; fi")
270270
end
271271

272272
desc "check if screenshots exists and exit"

0 commit comments

Comments
 (0)