Skip to content

Commit

Permalink
add build date to pr comment & edit isntead of recreate
Browse files Browse the repository at this point in the history
  • Loading branch information
emptyrivers committed May 12, 2024
1 parent accbb96 commit 3ae9479
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
7 changes: 5 additions & 2 deletions .github/pr-commenter.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
comment:
on-update: recreate
on-update: edit

glob-options:
dot: true
Expand All @@ -8,5 +8,8 @@ comment:
files:
- '**'
body: |
{{#build_id}}An experimental build of WeakAuras with the changes in this pull request is available [here](https://nightly.link/{{repository}}/actions/artifacts/{{build_id}}.zip).{{/build_id}}
{{#build_id}}
An experimental build of WeakAuras with the changes in this pull request is available [here](https://nightly.link/{{repository}}/actions/artifacts/{{build_id}}.zip).
Build Time: {{datestr}}
{{/build_id}}
{{^build_id}}Experimental build was unsuccessful. See the logs for details.{{/build_id}}
4 changes: 4 additions & 0 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,16 @@ jobs:
needs: [permission_check, build]
if: ${{ needs.permission_check.outputs.require-result == 'true' && needs.build.result == 'success' && contains(github.event.pull_request.labels.*.name, '🆕 Feature Preview')}}
steps:
- id: datestr
run: echo "datestr=${date}" >> $GITHUB_OUTPUT

- uses: exercism/[email protected]
with:
github-token: ${{ github.token }}
config-file: ".github/pr-commenter.yml"
template-variables: |
{
"datestr": "${{ steps.datestr.outputs.datestr }}",
"repository": "${{ github.repository }}",
"build_id": "${{ needs.build.outputs.artifact-id }}",
"run_id": "${{ github.run_id }}"
Expand Down

0 comments on commit 3ae9479

Please sign in to comment.