From b8fe99e0316fa76ba62ac6abcb2cfb9d455892da Mon Sep 17 00:00:00 2001 From: Philipp Bammes <8144115+tyrann0us@users.noreply.github.com> Date: Thu, 22 Aug 2024 09:52:35 +0200 Subject: [PATCH] feat: remove deprecated input * fix: re-add current branch fallback Co-authored-by: Volodymyr Shelmuk Signed-off-by: Philipp Bammes <8144115+tyrann0us@users.noreply.github.com> * fix: remove condition * Revert "fix: remove condition" This reverts commit 2d233e03e70e602d7611e3d7da6122932d48ebda. --------- Signed-off-by: Philipp Bammes <8144115+tyrann0us@users.noreply.github.com> Co-authored-by: Volodymyr Shelmuk Co-authored-by: Luis Rosales --- .github/workflows/build-and-push-assets.yml | 14 ++------------ docs/build-and-push-assets.md | 1 - 2 files changed, 2 insertions(+), 13 deletions(-) diff --git a/.github/workflows/build-and-push-assets.yml b/.github/workflows/build-and-push-assets.yml index b9689f5c..af2f3463 100644 --- a/.github/workflows/build-and-push-assets.yml +++ b/.github/workflows/build-and-push-assets.yml @@ -53,11 +53,6 @@ on: default: '' required: false type: string - BUILT_BRANCH_SUFFIX: - description: Suffix to calculate the target branch for pushing assets on the `branch` event (deprecated). - type: string - default: '' - required: false BUILT_BRANCH_NAME: description: Sets the target branch for pushing assets on the `branch` event. type: string @@ -152,11 +147,6 @@ jobs: LOCK_FILE: '' # we'll override after checking files NO_CHANGES: '' # we'll override if no changes to commit steps: - - name: Deprecation warning - if: ${{ inputs.BUILT_BRANCH_SUFFIX != '' }} - run: | - echo '::warning::The BUILT_BRANCH_SUFFIX input is deprecated and will be removed soon. Please update your workflow to use BUILT_BRANCH_NAME with ${{ github.ref_name }}-built.' - - name: Checkout uses: actions/checkout@v4 with: @@ -212,7 +202,7 @@ jobs: - name: Set branch environment variables if: ${{ github.ref_type == 'branch' }} run: | - echo "BUILT_BRANCH_NAME=${{ inputs.BUILT_BRANCH_NAME && inputs.BUILT_BRANCH_NAME || format('{0}{1}', github.ref_name, inputs.BUILT_BRANCH_SUFFIX) }}" >> $GITHUB_ENV + echo "BUILT_BRANCH_NAME=${{ inputs.BUILT_BRANCH_NAME && inputs.BUILT_BRANCH_NAME || github.ref_name }}" >> $GITHUB_ENV - name: Set tag environment variables if: ${{ github.ref_type == 'tag' }} @@ -290,7 +280,7 @@ jobs: git commit -m "[BOT] Add compiled assets for #${{ github.ref }}" --no-verify || ((echo "NO_CHANGES=yes" >> $GITHUB_ENV) && (echo "No changes to commit")) - name: Git push for branch - if: ${{ github.ref_type == 'branch' && (env.NO_CHANGES != 'yes' || inputs.BUILT_BRANCH_SUFFIX != '' || inputs.BUILT_BRANCH_NAME != '') }} + if: ${{ github.ref_type == 'branch' && (env.NO_CHANGES != 'yes' || inputs.BUILT_BRANCH_NAME != '') }} run: git push - name: Git push for tag diff --git a/docs/build-and-push-assets.md b/docs/build-and-push-assets.md index 787e2b0f..d5fd9459 100644 --- a/docs/build-and-push-assets.md +++ b/docs/build-and-push-assets.md @@ -106,7 +106,6 @@ This is not the simplest possible example, but it showcases all the recommendati | `MODE` | `''` | Mode for compiling assets (`prod` or `dev`) | | `ASSETS_TARGET_PATHS` | `'./assets'` | Space-separated list of target directory paths for compiled assets | | `ASSETS_TARGET_FILES` | `''` | Space-separated list of target file paths for compiled assets | -| `BUILT_BRANCH_SUFFIX` | `''` | :warning: deprecated - Suffix to calculate the target branch for pushing assets on the `branch` event | | `BUILT_BRANCH_NAME` | `''` | Sets the target branch for pushing assets on the `branch` event | | `RELEASE_BRANCH_NAME` | `''` | On tag events, target branch where compiled assets are pushed and the tag is moved to | | `PHP_VERSION` | `'8.0'` | PHP version with which the PHP tools are to be executed |