cordova-plugin-insider 1.4.0 → 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,37 +0,0 @@
1
- #!/usr/bin/env bash
2
-
3
- NEW_CV_VERSION_NAME=$1
4
-
5
- packagejson_file_path="package.json"
6
- gradle_file_path="src/android/build-extras.gradle"
7
- pluginxml_file_path="plugin.xml"
8
- constants_file_path="www/Constants.js"
9
-
10
- CURRENT_CV_SDK_VERSION=$(sed -n 3p $packagejson_file_path | cut -d '"' -f 4)
11
-
12
- CURRENT_ANDROID_VERSION=$(sed -n 22p $gradle_file_path | awk '{print $2}' | awk -F : '{print $3}' | cut -d "'" -f 1)
13
- CURRENT_ANDROID_HYBRID_VERSION=$(sed -n 23p $gradle_file_path | awk '{print $2}' | awk -F : '{print $3}' | cut -d "'" -f 1)
14
-
15
- CURRENT_iOS_VERSION=$(sed -n 74p $pluginxml_file_path | awk '{print $3}' | cut -d '"' -f 2)
16
- CURRENT_iOS_HYBRID_VERSION=$(sed -n 75p $pluginxml_file_path | awk '{print $3}' | cut -d '"' -f 2)
17
-
18
- LATEST_iOS_VERSION=$(aws s3 ls s3://mobilesdk.useinsider.com/iOS/ --recursive | sort | tail -n 1 | awk '{print $4}' | awk -F / '{print $2}')
19
- LATEST_iOS_HYBRID_VERSION=$(aws s3 ls s3://mobilesdk.useinsider.com/iOSHybrid/ --recursive | sort | tail -n 1 | awk '{print $4}' | awk -F / '{print $2}')
20
-
21
- LATEST_ANDROID_VERSION=$(aws s3 ls s3://mobilesdk.useinsider.com/android/com/useinsider/insider/ --recursive | sort | tail -n 1 | awk '{print $4}' | awk -F / '{print $5}' | cut -d "-" -f 1)
22
- LATEST_ANDROID_HYBRID_VERSION=$(aws s3 ls s3://mobilesdk.useinsider.com/android/com/useinsider/insiderhybrid/ --recursive | sort | tail -n 1 | awk '{print $4}' | awk -F / '{print $5}')
23
-
24
- # Set new version in plugin.xml
25
- sed -i "s/$CURRENT_CV_SDK_VERSION/$NEW_CV_VERSION_NAME/" $pluginxml_file_path
26
-
27
- # Set new sdk version in Constant.js
28
- sed -i "s/$CURRENT_CV_SDK_VERSION/$NEW_CV_VERSION_NAME/" $constants_file_path
29
-
30
- # Set new version in package.json
31
- sed -i "s/$CURRENT_CV_SDK_VERSION/$NEW_CV_VERSION_NAME/" $packagejson_file_path
32
-
33
- # Set new version in plugin.xml for ios
34
- sed -i "s/$CURRENT_iOS_VERSION/$LATEST_iOS_VERSION/;s/$CURRENT_iOS_HYBRID_VERSION/$LATEST_iOS_HYBRID_VERSION/" $pluginxml_file_path
35
-
36
- # Set new version in build.gradle
37
- sed -i "s/$CURRENT_ANDROID_VERSION/$LATEST_ANDROID_VERSION/;s/$CURRENT_ANDROID_HYBRID_VERSION/$LATEST_ANDROID_HYBRID_VERSION/" $gradle_file_path
package/slack_notifier.sh DELETED
@@ -1,20 +0,0 @@
1
- #!/usr/bin/env bash
2
- SLACK_ENDPOINT="https://mobile.useinsider.com/api/lilith/slack_notifier"
3
-
4
- CHANNEL=$1
5
- USERNAME=$2
6
- TEXT="$3"
7
-
8
- generate_post_data()
9
- {
10
- cat <<EOF
11
- {
12
- "channel": "$CHANNEL",
13
- "message": "$TEXT",
14
- "username": "$USERNAME",
15
- "auth_key": "$SLACK_NOTIFIER_AUTH_KEY"
16
- }
17
- EOF
18
- }
19
-
20
- curl -i -H "Content-Type:application/json" -X POST --data "$(generate_post_data)" $SLACK_ENDPOINT >/dev/null 2>&1