From 501048b1176fe5546e2e562a87f470d5b54c8ea7 Mon Sep 17 00:00:00 2001 From: Fares Abawi Date: Thu, 18 Jan 2024 11:01:50 +0100 Subject: [PATCH] Update manual_code_coverage.yml --- .github/workflows/manual_code_coverage.yml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/manual_code_coverage.yml b/.github/workflows/manual_code_coverage.yml index 8c1c46b..253148a 100644 --- a/.github/workflows/manual_code_coverage.yml +++ b/.github/workflows/manual_code_coverage.yml @@ -61,9 +61,15 @@ jobs: # Step 7: Modify codecov paths - name: Modify paths in coverage.xml run: | - sed -i 's|.opt.conda.envs.zeromq_yarp_ros2.lib.python3.10.site-packages.wrapyfi|.|g' ${GITHUB_WORKSPACE}/shared_directory/coverage.xml - sed -i 's|/opt/conda/envs/zeromq_yarp_ros2/lib/python3.10/site-packages/wrapyfi||g' ${GITHUB_WORKSPACE}/shared_directory/coverage.xml - cat ${GITHUB_WORKSPACE}/shared_directory/coverage.xml # Optional: Print to verify + # Set the source directory to /wrapyfi + sed -i 's||/wrapyfi|g' ${GITHUB_WORKSPACE}/shared_directory/coverage.xml + # Remove the old source tag if it exists + sed -i '/.*<\/source>/d' ${GITHUB_WORKSPACE}/shared_directory/coverage.xml + # Modify file paths by removing the unnecessary path prefix and leading ./ + sed -i 's|filename="./opt/conda/envs/zeromq_yarp_ros2/lib/python3.10/site-packages/wrapyfi/|filename="|g' ${GITHUB_WORKSPACE}/shared_directory/coverage.xml + sed -i 's|filename=".|filename="|g' ${GITHUB_WORKSPACE}/shared_directory/coverage.xml + # Optional: Print to verify + cat ${GITHUB_WORKSPACE}/shared_directory/coverage.xml # Step 8: Upload the coverage report (remains unchanged)