Skip to content

Commit

Permalink
Merge pull request #590 from cyclus/pr-comment-hash
Browse files Browse the repository at this point in the history
Add commit hash to PR comment
  • Loading branch information
gonuke committed Mar 24, 2024
2 parents 945211c + 9ab624a commit dd7b431
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 4 deletions.
14 changes: 12 additions & 2 deletions .github/workflows/build_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,12 +120,22 @@ jobs:
runs-on: ubuntu-latest
if: github.event_name == 'pull_request'
steps:
- name: Checkout cycamore
uses: actions/checkout@v4

- name: Save PR number to file
run: |
echo "${{ github.event.number }}" > pr_number
echo "${{ github.event.pull_request.head.sha }} - $(git log -1 --format=%ci)" > commit_hash_timestamp
- name: Upload artifact
- name: Upload PR number artifact
uses: actions/upload-artifact@v4
with:
name: pr_number
path: pr_number
path: pr_number

- name: Upload Commit hash artifact
uses: actions/upload-artifact@v4
with:
name: commit_hash_timestamp
path: commit_hash_timestamp
2 changes: 1 addition & 1 deletion .github/workflows/pr_comment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:

- name: Merge artifacts and get PR number
run: |
echo "### Build Status Report" > artifacts_merged.md
echo "### Build Status Report - $(cat commit_hash_timestamp)" > artifacts_merged.md
cat ./*.txt >> artifacts_merged.md
echo "PR_NUMBER=$(cat pr_number)" >> "$GITHUB_ENV"
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ cycamore Change Log

* Downstream testing in CI workflows (#573, #580, #582, #583)
* GitHub workflow for publishing images on release (#573, #582, #583)
* GitHub workflows for building/testing on a PR and push to `main` (#549, #564, #573, #582, #583)
* GitHub workflows for building/testing on a PR and push to `main` (#549, #564, #573, #582, #583, #590)
* Add functionality for random behavior on the size (#550) and frequency (#565) of a sink
* GitHub workflow to check that the CHANGELOG has been updated (#562)
* Added inventory policies to Storage through the material buy policy (#574, #588)
Expand Down

0 comments on commit dd7b431

Please sign in to comment.