Retire legacy implementations and flatten managed layout
This commit is contained in:
Executable
+35
@@ -0,0 +1,35 @@
|
||||
#!/bin/sh
|
||||
set -eu
|
||||
|
||||
root="$(CDPATH= cd -- "$(dirname -- "$0")/../.." && pwd)"
|
||||
device="${VOICECAT_IOS_DEVICE:-}"
|
||||
configuration="${CONFIGURATION:-Debug}"
|
||||
build=true
|
||||
console=false
|
||||
|
||||
while [ "$#" -gt 0 ]; do
|
||||
case "$1" in
|
||||
--device) device="$2"; shift 2 ;;
|
||||
--configuration) configuration="$2"; shift 2 ;;
|
||||
--no-build) build=false; shift ;;
|
||||
--console) console=true; shift ;;
|
||||
--list) xcrun devicectl list devices; exit 0 ;;
|
||||
-h|--help)
|
||||
echo "usage: $0 --device NAME-OR-UDID [--configuration Debug|Release] [--no-build] [--console]"
|
||||
echo "use --list to show devices, or set VOICECAT_IOS_DEVICE"
|
||||
exit 0 ;;
|
||||
*) echo "unknown argument: $1" >&2; exit 2 ;;
|
||||
esac
|
||||
done
|
||||
|
||||
[ -n "$device" ] || { echo "pass --device NAME-OR-UDID or set VOICECAT_IOS_DEVICE" >&2; exit 2; }
|
||||
app="$root/dist/ios-managed-device/VoiceCat.iOS.app"
|
||||
if $build; then "$root/clients/apple/build-ios-device.sh" --configuration "$configuration"; fi
|
||||
[ -d "$app" ] || { echo "managed device app not found at $app; run build-ios-device.sh first" >&2; exit 1; }
|
||||
|
||||
xcrun devicectl device install app --device "$device" "$app"
|
||||
if $console; then
|
||||
xcrun devicectl device process launch --device "$device" --terminate-existing --console me.iamtalon.voicecat
|
||||
else
|
||||
xcrun devicectl device process launch --device "$device" --terminate-existing me.iamtalon.voicecat
|
||||
fi
|
||||
Reference in New Issue
Block a user