fix(deploy): subtitle fallback + realistic runtime seeds

- subtitle now falls back to last non-empty log line when no Compile/Build
  action matched yet (so user sees activity during xcodebuild setup phase
  instead of empty bar at 0%)
- realistic seeds: 22min → 8min for xcarchive (typical RN archive)
This commit is contained in:
chahinebrini 2026-05-30 09:55:53 +02:00
parent e6e1bab35a
commit b15ee42a85

View File

@ -184,11 +184,20 @@ run_quiet() {
RUN_QUIET_I=$((RUN_QUIET_I + 1))
subtitle=""
if [[ -f "$logfile" ]]; then
# Primary: meaningful build action (filtered)
subtitle=$(tail -20 "$logfile" 2>/dev/null \
| grep -aE '^(Compiling|CompileSwift|CompileC|Linking|Ld|Touch|CodeSign|ProcessProductPackaging|ExtractAppIntentsMetadata|Validate|Archive|GenerateAssetSymbols|CopySwiftLibs|PhaseScriptExecution|> Task|BUILD|\[CP|\[Pods)' \
| tail -1 \
| sed -E 's|.*/||; s|\(.*||' \
| cut -c1-50)
# Fallback: any last non-empty line (so user sees activity during setup/parsing)
if [[ -z "$subtitle" ]]; then
subtitle=$(tail -5 "$logfile" 2>/dev/null \
| grep -av '^[[:space:]]*$' \
| tail -1 \
| sed -E 's|^[[:space:]]+||' \
| cut -c1-50)
fi
fi
render_progress "$elapsed" "$expected" "$label" "$subtitle"
sleep 0.2