-
Notifications
You must be signed in to change notification settings - Fork 0
/
deploy
executable file
·27 lines (19 loc) · 1.04 KB
/
deploy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/bash
echo -e "\n\e[96m === exit script if anything fails ===\e[0m"
set -e
echo -e "\n\e[96m === cd into flutter app directory for Encrateia ===\e[0m"
cd "/home/stefan/flutter/encrateia"
echo -e "\n\e[96m === build apks ===\e[0m"
flutter build apk --split-per-abi
export APK_SOURCE_PATH='/home/stefan/flutter/encrateia/build/app/outputs/apk/release'
export JEKYLL_DOWNLOAD_DIR='/home/stefan/jekyll/encrateia.informatom.com/download/'
echo -e "\n\e[96m === copy current apk's into Jekyll assets ===\e[0m"
cp $APK_SOURCE_PATH/app-armeabi-v7a-release.apk $JEKYLL_DOWNLOAD_DIR
cp $APK_SOURCE_PATH/app-arm64-v8a-release.apk $JEKYLL_DOWNLOAD_DIR
cp $APK_SOURCE_PATH/app-x86_64-release.apk $JEKYLL_DOWNLOAD_DIR
echo -e "\n\e[96m === cd into Jekyll site directory ===\e[0m"
cd /home/stefan/jekyll/encrateia.informatom.com/
echo -e "\n\e[96m === build Jekyll release ===\e[0m"
jekyll build
echo -e "\n\e[96m === rsync to Server ===\e[0m"
rsync -vr /home/stefan/jekyll/encrateia.informatom.com/_site/ stefan@alpha:/var/www/encrateia.informatom.com/html --delete