You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
13 lines
321 B
Bash
13 lines
321 B
Bash
#!/bin/sh
|
|
|
|
set -ex
|
|
cd android || exit 1
|
|
target=app/build.gradle
|
|
newVersion=$(grep '^\s*versionCode [0-9]*$' "$target" | awk '{print $2+1}')
|
|
sed -i "s/\(^\s*\)versionCode [0-9]*$/\1versionCode $newVersion/" \
|
|
"$target"
|
|
./gradlew bundleRelease
|
|
git add app/build.gradle
|
|
git commit -m "Bundle version $newVersion"
|
|
cd ..
|