1- RELEASE=v0.3.2
2- ASSET_NAME=library-ios-android.tar.gz
3- ASKAR_URL=" https://github.com/openwallet-foundation/askar/releases/download/$RELEASE /$ASSET_NAME "
4- TARGET_DIR=" android/app/src/main/jniLibs"
5-
6- # Create the target directory if it doesn't exist
7- mkdir -p " $TARGET_DIR "
8-
9- # Download the tar.gz file
10- echo " Downloading $ASKAR_URL ..."
11- curl -L " $ASKAR_URL " -o " $TARGET_DIR /$ASSET_NAME "
12-
13- # Extract the contents to a temporary directory
14- TEMP_DIR=$( mktemp -d)
15- echo " Extracting contents..."
16- tar -xzf " $TARGET_DIR /$ASSET_NAME " -C $TEMP_DIR
17-
18- # Move the mobile/android directory to the target directory
19- echo " Moving mobile/android to $TARGET_DIR ..."
20- mv $TEMP_DIR /mobile/android/* $TARGET_DIR
21-
22- # Clean up the temporary directory and the downloaded tar.gz file
23- rm -rf $TEMP_DIR
24- rm " $TARGET_DIR /$ASSET_NAME "
25-
26- # Copy library to example
27- cp -r " $TARGET_DIR " " example/$TARGET_DIR "
28-
1+ RELEASE=v0.3.2
2+ ASSET_NAME=library-ios-android.tar.gz
3+ ASKAR_URL=" https://github.com/openwallet-foundation/askar/releases/download/$RELEASE /$ASSET_NAME "
4+ TARGET_DIR=" android/app/src/main/jniLibs"
5+
6+ # Create the target directory if it doesn't exist
7+ mkdir -p " $TARGET_DIR "
8+
9+ # Download the tar.gz file
10+ echo " Downloading $ASKAR_URL ..."
11+ curl -L " $ASKAR_URL " -o " $TARGET_DIR /$ASSET_NAME "
12+
13+ # Extract the contents to a temporary directory
14+ TEMP_DIR=$( mktemp -d)
15+ echo " Extracting contents..."
16+ tar -xzf " $TARGET_DIR /$ASSET_NAME " -C $TEMP_DIR
17+
18+ # Move the mobile/android directory to the target directory
19+ echo " Moving mobile/android to $TARGET_DIR ..."
20+ mv $TEMP_DIR /mobile/android/* $TARGET_DIR
21+
22+ # Clean up the temporary directory and the downloaded tar.gz file
23+ rm -rf $TEMP_DIR
24+ rm " $TARGET_DIR /$ASSET_NAME "
25+
26+ # Copy library to example
27+ cp -r " $TARGET_DIR " " example/$TARGET_DIR "
28+
2929echo " Done!"
0 commit comments