From d6cdefcf6b5c1b146080aa4fea3348d4540d46f9 Mon Sep 17 00:00:00 2001 From: Ryan Hughes Date: Fri, 22 May 2026 12:26:51 -0400 Subject: [PATCH] installer: recover install start time from log --- install/helpers/logging.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/install/helpers/logging.sh b/install/helpers/logging.sh index d215838e..f830a6c5 100644 --- a/install/helpers/logging.sh +++ b/install/helpers/logging.sh @@ -88,7 +88,12 @@ stop_install_log() { fi fi - if [[ -n $OMARCHY_START_TIME ]]; then + if [[ -z ${OMARCHY_START_TIME:-} ]] && [[ -f "$OMARCHY_INSTALL_LOG_FILE" ]]; then + OMARCHY_START_TIME=$(grep -m1 '^=== Omarchy Installation Started:' "$OMARCHY_INSTALL_LOG_FILE" 2>/dev/null | + sed 's/^=== Omarchy Installation Started: \(.*\) ===$/\1/' || true) + fi + + if [[ -n ${OMARCHY_START_TIME:-} ]]; then OMARCHY_START_EPOCH=$(date -d "$OMARCHY_START_TIME" +%s) OMARCHY_END_EPOCH=$(date -d "$OMARCHY_END_TIME" +%s) OMARCHY_DURATION=$((OMARCHY_END_EPOCH - OMARCHY_START_EPOCH))