Skip to content

Commit aef1574

Browse files
committed
only grab filename for partials
1 parent 054da0e commit aef1574

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

.github/workflows/potential-redirects-or-partials.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ jobs:
4444
files=$(curl -s -H "Authorization: Bearer $GITHUB_TOKEN" \
4545
-H "Accept: application/vnd.github.v3+json" \
4646
"https://api.github.com/repos/${{ github.repository }}/pulls/${{ github.event.pull_request.number }}/files" | \
47-
jq -r '.[] | select(.status=="modified") | select (.filename | startswith("src/content/partials")) | select(.filename | endswith(".mdx"))' | \
47+
jq -r '.[] | select(.status=="modified") | select (.filename | startswith("src/content/partials")) | select(.filename | endswith(".mdx")) | .filename' | \
4848
sed -e 's|^src/content/partials||' -e 's|\.mdx$|/|')
4949
# Use random delimiter for security reasons
5050
delimiter="$(openssl rand -hex 8)"
@@ -84,7 +84,7 @@ jobs:
8484
for path in $CHANGED_FILES; do
8585
clean_path=$(echo "$path" | sed 's/"//g') # Remove quotation marks
8686
comment_body="$comment_body
87-
- [ ] \`$clean_path\`"
87+
- [ ] \`$clean_path\`"
8888
done
8989
fi
9090
@@ -96,7 +96,7 @@ jobs:
9696
This PR updates partial files, which are bits of content used across multiple files."
9797
for path in $PARTIAL_FILES; do
9898
comment_body="$comment_body
99-
- [ ] \`$path\`"
99+
- [ ] \`$path\`"
100100
done
101101
fi
102102

0 commit comments

Comments
 (0)