diff options
author | cyberta <cyberta@riseup.net> | 2023-01-23 19:47:56 +0100 |
---|---|---|
committer | cyberta <cyberta@riseup.net> | 2023-01-23 19:47:56 +0100 |
commit | 7d0a1f8d8057faa74035de0cee262a46c6fbbe00 (patch) | |
tree | beb7ae926be396c9faff6978677d74c466d3e20f /scripts/fastlane.sh | |
parent | a800ef1e82c25207a842c197190b614e43739051 (diff) |
setup fastlane to create screenshots for Bitmask and custom branded clients, refactor Tests accordingly and create a script and environment variables to run fastlane screenshotting without thinking
Diffstat (limited to 'scripts/fastlane.sh')
-rwxr-xr-x | scripts/fastlane.sh | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/scripts/fastlane.sh b/scripts/fastlane.sh new file mode 100755 index 00000000..f039cd24 --- /dev/null +++ b/scripts/fastlane.sh @@ -0,0 +1,34 @@ +#!/bin/bash + +GREEN='\033[0;32m' +RED='\033[0;31m' +NC='\033[0m' + +# init parameters +if [[ ${1} = "custom" ]]; then + BUILD_CUSTOM=true +elif [[ ! -z ${1} ]]; then + echo -e """${RED}Failed due to wrong arguments.${NC} + Usage: + ====== + ${GREEN}create screenshots for Bitmask:${NC} + ./fastlane.sh + + ${GREEN}create screenshots for your custom build${NC} (please adopt the environment variables in './fastlane/.env.custom'): + ./fastlane.sh custom + """ + exit 1 +fi; + +#screengrab related environment variables can be found in ./fastlane/.env.* +SCRIPT_DIR=$(dirname "$0") +BASE_DIR="$SCRIPT_DIR/.." + +cd $BASE_DIR +if [[ -z $BUILD_CUSTOM ]]; then + fastlane android bitmask_screenshots +else + fastlane android custom_build_screenshots --env custom +fi; +cd - + |