From 682f0b5022bb43458cc403ac4ae9aaca0e9f02cd Mon Sep 17 00:00:00 2001
From: Martin Weise <martin.weise@tuwien.ac.at>
Date: Wed, 18 Dec 2024 13:43:40 -0500
Subject: [PATCH] WIP

---
 .gitlab/gen-badge.sh | 13 +++++++------
 .jupyter/Pipfile     |  2 +-
 2 files changed, 8 insertions(+), 7 deletions(-)

diff --git a/.gitlab/gen-badge.sh b/.gitlab/gen-badge.sh
index f09f4d619b..e5bb815915 100644
--- a/.gitlab/gen-badge.sh
+++ b/.gitlab/gen-badge.sh
@@ -1,14 +1,15 @@
 #!/bin/bash
-GITLAB_URL="https://gitlab.phaidra.org"
-# if we reached this script, all the tests have passed
 anybadge --label pipeline --value "passed" failed=red passed=green canceled=darkgray > "./final/${DOC_VERSION}/images/pipeline.svg"
-PIPELINE_COVERAGE=$(curl -fsSL -H "PRIVATE-TOKEN: ${CI_TOKEN}" "${GITLAB_URL}/api/v4/projects/450/pipelines/latest?ref=${CI_COMMIT_BRANCH}" | jq --raw-output .coverage)
+PIPELINE_COVERAGE=$(curl -fsSL -H "PRIVATE-TOKEN: ${CI_TOKEN}" "${GITLAB_URL}/api/v4/projects/${GITLAB_PROJECT_ID}/pipelines/latest?ref=${CI_COMMIT_BRANCH}" | jq --raw-output .coverage)
+
 echo "[INFO] pipeline coverage: ${PIPELINE_COVERAGE}"
 if [ "${PIPELINE_COVERAGE}" != "null" ]; then
   anybadge --label coverage --value "${PIPELINE_COVERAGE}" coverage > "./final/${DOC_VERSION}/images/coverage.svg"
 else
   echo "[WARNING] Skipping badge generation, displaying default badge text: unknown"
 fi
-curl "${CI_SONAR_URL}/api/project_badges/measure?project=${CI_SONAR_PROJECT_KEY}&metric=sqale_rating&token=${CI_SONAR_TOKEN}" > "./final/${DOC_VERSION}/images/maintainability.svg"
-curl "${CI_SONAR_URL}/api/project_badges/measure?project=${CI_SONAR_PROJECT_KEY}&metric=security_rating&token=${CI_SONAR_TOKEN}" > "./final/${DOC_VERSION}/images/security.svg"
-echo "[INFO] retrieved SonarQube badges"
\ No newline at end of file
+
+curl -fsSL "${CI_SONAR_URL}/api/project_badges/measure?project=${CI_SONAR_PROJECT_KEY}&metric=sqale_rating&token=${CI_SONAR_TOKEN}" > "./final/${DOC_VERSION}/images/maintainability.svg"
+curl -fsSL "${CI_SONAR_URL}/api/project_badges/measure?project=${CI_SONAR_PROJECT_KEY}&metric=security_rating&token=${CI_SONAR_TOKEN}" > "./final/${DOC_VERSION}/images/security.svg"
+
+echo "[INFO] retrieved badges"
\ No newline at end of file
diff --git a/.jupyter/Pipfile b/.jupyter/Pipfile
index 1c278cad15..97e298ffc2 100644
--- a/.jupyter/Pipfile
+++ b/.jupyter/Pipfile
@@ -9,4 +9,4 @@ notebook = "*"
 python-dotenv = "*"
 
 [requires]
-python_version = "3.11"
+python_version = "3.11"
\ No newline at end of file
-- 
GitLab