Merge remote-tracking branch 'origin/pj/fix/ci/release' into staging

This commit is contained in:
Anton Livaja 2024-09-06 11:28:30 -04:00
commit 68aeb243b6
No known key found for this signature in database
GPG key ID: 44A86CFF1FDF0E85

View file

@ -13,14 +13,9 @@ defaults:
jobs:
check:
name: Check if non-staging -> main
runs-on: shell
if: github.base_ref == 'main'
if: github.base_ref == 'main' && !startsWith(github.ref, 'refs/heads/release/') && github.head_ref != 'staging'
steps:
- name: Check if non-staging -> main
if: github.head_ref != 'staging'
run: echo 'Cannot merge non-staging branch to main'; exit 1
- name: Check if staging -> main
if: github.head_ref == 'staging'
run: echo 'Merge from staging branch to main allowed'; exit 0