Skip to content

Commit c6747a5

Browse files
authored
build: prepend working directory path
Signed-off-by: Philipp Burckhardt <[email protected]>
1 parent f13c588 commit c6747a5

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

.github/workflows/cleanup_coverage.yml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,8 @@ jobs:
9494
# Find and delete unneeded coverage directories:
9595
- name: 'Find and delete unneeded coverage directories'
9696
run: |
97-
echo "Current working directory: $(pwd)"
98-
echo "Listing top-level directories:"
99-
ls -la
97+
WORKING_DIR=$(pwd)
98+
echo "Current working directory: $WORKING_DIR"
10099
101100
# Find all coverage directories:
102101
find . \
@@ -131,12 +130,12 @@ jobs:
131130
if [ -z "$dir" ]; then
132131
continue
133132
fi
134-
if [ -d "$dir" ]; then
135-
rm -r -- "$dir"
136-
elif [ -d "./$dir" ]; then
137-
rm -r -- "./$dir"
133+
full_path="$WORKING_DIR/$dir"
134+
if [ -d "$full_path" ]; then
135+
echo "Removing directory: $full_path"
136+
rm -r -- "$full_path"
138137
else
139-
echo "Warning: Directory not found: $dir"
138+
echo "Warning: Directory not found: $full_path"
140139
fi
141140
done < dirs_to_remove.txt
142141

0 commit comments

Comments
 (0)