From 579898507f81cfd97418283df6a4f35d8d0ce0b2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jonas=20H=C3=B6ppner?= <jonas.hoeppner@garz-fricke.com>
Date: Fri, 9 Dec 2022 13:20:31 +0100
Subject: [PATCH] CI:debug add timestamps

---
 build-yocto.yml | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/build-yocto.yml b/build-yocto.yml
index 7a1067e1..4400c1de 100644
--- a/build-yocto.yml
+++ b/build-yocto.yml
@@ -1,5 +1,12 @@
 ---
 
+.timestamp: &timestamp
+  - |-
+    now=$(date +%s)
+    lasttime=${lastime-now}
+    sincelast=$(( now - lasttime ))
+    echo "Section timestamp $( date -R -d"@$now" ) -- duration $sincelast seconds"
+
 .networkdebug: &networkdebug
   #
   - |-
@@ -94,15 +101,25 @@
     JOB_URL: "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/jobs/${CI_JOB_ID}/artifacts/"
     FNG_INSTALL_PATH: "${BUILDPATH}/${IMAGEPATH}/${INSTALLSCRIPT}"
   before_script:
+    - *timestamp
     - *networkdebug
+    - *timestamp
     - !reference [.docker_check]
+    - *timestamp
     - !reference [.setup_ssh]
+    - *timestamp
     - !reference [.repo_checkout]
+    - *timestamp
   script:
+    - *timestamp
     - *save_build_env
+    - *timestamp
     - *build_script
+    - *timestamp
     - *collect_srcrevs
+    - *timestamp
     - *dump_install_command
+    - *timestamp
   artifacts:
     reports:
       dotenv: build.env
-- 
GitLab