Skip to content

Commit fcff88a

Browse files
committed
New step for bundle name
1 parent 7f6185b commit fcff88a

File tree

1 file changed

+11
-6
lines changed

1 file changed

+11
-6
lines changed

.github/workflows/deploy_latest_release.yml

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,17 @@ jobs:
3535
needs: check-latest-release
3636
runs-on: ubuntu-latest
3737
if: needs.check-latest-release.outputs.IS_LATEST_RELEASE != 'true'
38-
env:
39-
BUNDLE_NAME: "${{ github.event.release.tag_name }} && 'tag ${{ github.event.release.tag_name }}' || 'build ${{ github.run_id }} on ${{ github.ref }} (${{ github.sha }})' "
4038
steps:
41-
- name: Print bundle name
39+
- name: Set bundle name
4240
run: |-
43-
echo $BUNDLE_NAME
41+
TAG_NAME=$(echo ${{ github.event.release.tag_name }})
42+
if [ "$TAG_NAME" ]; then
43+
BUNDLE_NAME="tag ${{ github.event.release.tag_name }}"
44+
else
45+
BUNDLE_NAME="build ${{ github.run_id }} on ${{ github.ref }} (${{ github.sha }})""
46+
fi
47+
echo "Setting bundle name as $BUNDLE_NAME"
48+
echo "BUNDLE_NAME=$BUNDLE_NAME" >> $GITHUB_ENV
4449
4550
# - name: Checkout
4651
# uses: actions/checkout@v4
@@ -81,8 +86,6 @@ jobs:
8186
needs: check-latest-release
8287
runs-on: ubuntu-latest
8388
if: needs.check-latest-release.outputs.IS_LATEST_RELEASE == 'true'
84-
env:
85-
BUNDLE_NAME: "${{ $github.event.release.tag_name && 'tag $github.event.release.tag_name ' || 'build $github.run_id on github.ref ( github.sha )'}} "
8689
steps:
8790
- name: Checkout
8891
uses: actions/checkout@v4
@@ -110,6 +113,8 @@ jobs:
110113
mobify_user: ${{ secrets.MOBIFY_CLIENT_USER }}
111114
mobify_api_key: ${{ secrets.MOBIFY_CLIENT_API_KEY }}
112115

116+
117+
113118
- name: Push Bundle to MRT (Demo Site)
114119
uses: "./.github/actions/push_to_mrt"
115120
with:

0 commit comments

Comments
 (0)