Skip to content

Commit bd03d6a

Browse files
committed
fix: restrict to submodule diff only
1 parent 9b05e9a commit bd03d6a

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

.github/workflows/submodule.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,11 @@ jobs:
1818
- name: get changes
1919
id: changes
2020
run: |
21-
git diff origin/${{ github.base_ref }} --submodule=log | tee changes.txt
21+
for sm in $(grep 'path = ' .gitmodules | awk '{print $3}'); do
22+
echo "SUBMODULE $sm ===========" | tee changes.txt
23+
git diff origin/${{ github.base_ref }} --submodule=log -- $sm | tee changes.txt
24+
echo "" | tee changes.txt
25+
done
2226
echo "changes<<EOF" >> $GITHUB_OUTPUT
2327
cat changes.txt >> $GITHUB_OUTPUT
2428
echo "EOF" >> $GITHUB_OUTPUT

0 commit comments

Comments
 (0)