Explorar el Código

misc(tools) add script for updating mobile apps versions

master
Saúl Ibarra Corretgé hace 4 años
padre
commit
7a64bf006e
Se han modificado 1 ficheros con 19 adiciones y 0 borrados
  1. 19
    0
      resources/update-mobile-version.sh

+ 19
- 0
resources/update-mobile-version.sh Ver fichero

@@ -0,0 +1,19 @@
1
+#!/bin/bash
2
+
3
+set -e -u
4
+
5
+if [[ $# -ne 1 ]]; then
6
+    echo "Please specify a version"
7
+    exit 1
8
+fi
9
+
10
+THIS_DIR=$(cd -P "$(dirname "$(readlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
11
+VERSION=$1
12
+
13
+# iOS
14
+/usr/libexec/PlistBuddy -c "Set :CFBundleShortVersionString ${VERSION}" ${THIS_DIR}/../ios/app/src/Info.plist
15
+/usr/libexec/PlistBuddy -c "Set :CFBundleShortVersionString ${VERSION}" ${THIS_DIR}/../ios/app/watchos/app/Info.plist
16
+/usr/libexec/PlistBuddy -c "Set :CFBundleShortVersionString ${VERSION}" ${THIS_DIR}/../ios/app/watchos/extension/Info.plist
17
+
18
+# Android
19
+sed -i "" -e "s/appVersion=.*/appVersion=${VERSION}/" ${THIS_DIR}/../android/gradle.properties

Loading…
Cancelar
Guardar