Skip to content

Commit

Permalink
Merge #4089 Use checkout action for notify workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
HebaruSan committed May 19, 2024
2 parents e00cf14 + 6255443 commit 0a3adcc
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 4 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,8 @@ jobs:
notify-discord:
needs:
- test-release
- smoke-inflator
- upload-deb
- upload-rpm
- upload-inflator
Expand Down
9 changes: 6 additions & 3 deletions .github/workflows/notify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,13 @@ jobs:
notify:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
repository: DiscordHooks/github-actions-discord-webhook
path: webhook
fetch-depth: 1
- env:
WORKFLOW_NAME: ${{ inputs.name }}
HOOK_OS_NAME: ${{ runner.os }}
shell: bash
run: |
git clone --depth 1 https://github.com/DiscordHooks/github-actions-discord-webhook.git webhook
bash webhook/send.sh ${{ inputs.success && 'success' || 'failure' }} ${{ secrets.DISCORD_WEBHOOK }}
run: bash webhook/send.sh ${{ inputs.success && 'success' || 'failure' }} ${{ secrets.DISCORD_WEBHOOK }}
2 changes: 2 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,8 @@ jobs:

notify-discord:
needs:
- test-release
- smoke-inflator
- build-dmg
- build-deb
- build-rpm
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ All notable changes to this project will be documented in this file.
- [Multiple] Build nuget package, support netstandard2.0 build (#4039 by: HebaruSan)
- [Core] Use fully sanitized archive.org bucket names (#4043 by: HebaruSan)
- [Netkan] Omit duplicate inflation warnings in queue (#4071 by: HebaruSan)
- [Build] Refactor + Modernise Actions (#4082, #4088 by: techman83, HebaruSan; reviewed: HebaruSan)
- [Build] Refactor + Modernise Actions (#4082, #4088, #4089 by: techman83, HebaruSan; reviewed: HebaruSan)

## v1.34.4 (Niven)

Expand Down
8 changes: 8 additions & 0 deletions bin/ckan_merge_pr.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,14 @@ def merge_into(self, repo: CkanRepo, self_review: bool) -> bool:
if not branch:
print(f'PR #{self.pull_request.number} commit {self.pull_request.head.sha} not found!')
return False
pr_commits = self.pull_request.get_commits()
incomplete_checks = [run
for run in pr_commits[pr_commits.totalCount - 1].get_check_runs()
if run.status != 'completed'
or run.conclusion not in ('success', 'skipped')]
if incomplete_checks:
print('Incomplete checks:', ', '.join(ch.name for ch in incomplete_checks))
return False
# Valid; do it!
# repo.index.merge_tree doesn't auto resolve conflicts
repo.git.merge(branch, no_commit=True, no_ff=True)
Expand Down

0 comments on commit 0a3adcc

Please sign in to comment.