Skip to content

Commit e33c42a

Browse files
authored
Merge pull request #3091 from cmderdev/copilot/add-links-for-values
Link backticked values in branch workflow summary
2 parents 138cea5 + c61ed85 commit e33c42a

1 file changed

Lines changed: 16 additions & 6 deletions

File tree

.github/workflows/branches.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,16 +26,22 @@ jobs:
2626
- name: Summary - Merge operation started
2727
shell: bash
2828
run: |
29+
repo_url="${{ github.server_url }}/${{ github.repository }}"
30+
source_branch_url="$repo_url/tree/master"
31+
target_branch_url="$repo_url/tree/development"
32+
actor_url="${{ github.server_url }}/${{ github.actor }}"
33+
commit_url="$repo_url/commit/${{ github.sha }}"
34+
2935
echo "## 🔀 Update Branches - Workflow Summary" >> $GITHUB_STEP_SUMMARY
3036
echo "" >> $GITHUB_STEP_SUMMARY
3137
echo "### Merge Operation" >> $GITHUB_STEP_SUMMARY
3238
echo "" >> $GITHUB_STEP_SUMMARY
3339
echo "| Property | Value |" >> $GITHUB_STEP_SUMMARY
3440
echo "| --- | --- |" >> $GITHUB_STEP_SUMMARY
35-
echo "| Source Branch | \`master\` |" >> $GITHUB_STEP_SUMMARY
36-
echo "| Target Branch | \`development\` |" >> $GITHUB_STEP_SUMMARY
37-
echo "| Triggered by | @${{ github.actor }} |" >> $GITHUB_STEP_SUMMARY
38-
echo "| Commit | \`${{ github.sha }}\` |" >> $GITHUB_STEP_SUMMARY
41+
echo "| Source Branch | [\`master\`]($source_branch_url) |" >> $GITHUB_STEP_SUMMARY
42+
echo "| Target Branch | [\`development\`]($target_branch_url) |" >> $GITHUB_STEP_SUMMARY
43+
echo "| Triggered by | [@${{ github.actor }}]($actor_url) |" >> $GITHUB_STEP_SUMMARY
44+
echo "| Commit | [\`${{ github.sha }}\`]($commit_url) |" >> $GITHUB_STEP_SUMMARY
3945
echo "" >> $GITHUB_STEP_SUMMARY
4046
4147
# Runs a single command using the runners shell
@@ -51,10 +57,14 @@ jobs:
5157
if: success()
5258
shell: bash
5359
run: |
60+
repo_url="${{ github.server_url }}/${{ github.repository }}"
61+
source_branch_url="$repo_url/tree/master"
62+
target_branch_url="$repo_url/tree/development"
63+
5464
echo "### ✅ Merge Successful" >> $GITHUB_STEP_SUMMARY
5565
echo "" >> $GITHUB_STEP_SUMMARY
56-
echo "The \`master\` branch has been successfully merged into \`development\`." >> $GITHUB_STEP_SUMMARY
66+
echo "The [\`master\`]($source_branch_url) branch has been successfully merged into [\`development\`]($target_branch_url)." >> $GITHUB_STEP_SUMMARY
5767
echo "" >> $GITHUB_STEP_SUMMARY
5868
echo "**Merge type:** No fast-forward merge" >> $GITHUB_STEP_SUMMARY
5969
echo "" >> $GITHUB_STEP_SUMMARY
60-
echo "> The development branch is now synchronized with the latest changes from master." >> $GITHUB_STEP_SUMMARY
70+
echo "> The [\`development\`]($target_branch_url) branch is now synchronized with the latest changes from [\`master\`]($source_branch_url)." >> $GITHUB_STEP_SUMMARY

0 commit comments

Comments
 (0)