Skip to content

Commit cc7eff7

Browse files
committed
Regular Update (HKT 20260226031645887728)
1 parent 8901448 commit cc7eff7

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

.github/workflows/TelegramNotification.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,12 @@ jobs:
1616
- name: Compute changes
1717
id: changes
1818
run: |
19-
changes=$(git diff --stat HEAD~1 HEAD)
19+
if git rev-parse --verify HEAD~1 >/dev/null 2>&1;
20+
then
21+
changes=$(git diff --stat HEAD~1 HEAD)
22+
else
23+
changes=$(git show --stat HEAD)
24+
fi
2025
echo "changes<<EOF" >> $GITHUB_OUTPUT
2126
echo "$changes" >> $GITHUB_OUTPUT
2227
echo "EOF" >> $GITHUB_OUTPUT
@@ -30,8 +35,8 @@ jobs:
3035
message: |
3136
New Push to GitHub!
3237
33-
- Repository: ${{ github.repository }}
34-
- Branch: ${{ github.ref_name }}
38+
- Repository: [${{ github.repository }}](${{ github.server_url }}/${{ github.repository }})
39+
- Branch: [${{ github.ref_name }}](${{ github.server_url }}/${{ github.repository }}/tree/${{ github.ref_name }})
3540
- Commit: [${{ github.sha }}](${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }})
3641
3742
Changes:

0 commit comments

Comments
 (0)