Skip to content

Commit

Permalink
Update merge-requires.yml (#274)
Browse files Browse the repository at this point in the history
* Update merge-requires.yml

Debug release action

AB#10062

Signed-off-by: Paul Hewlett <1104895+eccles@users.noreply.github.com>

* Update merge-requires.yml

Fix github action

Remove the release requires logic - we dont want the release to be
triggered until we actually release otherwise the action erroneously
attempts to upload a wheel to pypi with a spurious 0.0.1 tag.
Additionally the release action publishes documentation to github pages
and that **must not** happen until we release.

This also simplifies logic in the merge-requires workflow - the test
for github.event_name == 'release' did not apparently work.

AB#10062

---------

Signed-off-by: Paul Hewlett <1104895+eccles@users.noreply.github.com>
  • Loading branch information
eccles authored Nov 20, 2024
1 parent 7710adb commit 6d61222
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 18 deletions.
19 changes: 3 additions & 16 deletions .github/workflows/merge-requires.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,16 @@
# This workflow configures the repository specific choices of which CI builds
# must pass in order for a build to merge. This allows a sinlge global teraform
# must pass in order for a build to merge. This allows a single global teraform
# configured rule to require a "well known" check in each repository. Whilst
# granting repository stakeholders the ability configure what workflows are
# appropriate to satisfy that check.
name: Merge Requires
on:
push:

on: [pull_request]

jobs:
ci:
secrets: inherit
uses: ./.github/workflows/ci.yml
release:
if: ${{ github.event_name == 'release' }}
secrets: inherit
uses: ./.github/workflows/package.yml

merge-checks-ok:
runs-on: ubuntu-latest
Expand All @@ -23,12 +19,3 @@ jobs:
- name: ok
run: |
echo "This code is mergeable"
release-checks-ok:
runs-on: ubuntu-latest
if: ${{ github.event_name == 'release' }}
needs: [ci, release]
steps:
- name: ok
run: |
echo "This code is releasable"
5 changes: 3 additions & 2 deletions .github/workflows/package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@
name: Package and Publish

on:
workflow_call:
release:
types: [created]

jobs:
build:
deploy:

runs-on: ubuntu-latest

Expand Down

0 comments on commit 6d61222

Please sign in to comment.