@@ -24,15 +24,11 @@ jobs:
2424
2525 - name : " Print default branch"
2626 run : |
27- echo 'Default branch: ${{ fromJson(steps.get_default_branch.outputs.data).default_branch }}'
28- echo "##[set-output name=branch;]$(echo '${{ fromJson(steps.get_default_branch.outputs.data).default_branch }}')"
27+ DEFAULT_BRANCH='${{ fromJson(steps.get_default_branch.outputs.data).default_branch }}'
28+ echo 'Default branch: '$DEFAULT_BRANCH
29+ echo "DEFAULT_BRANCH=${DEFAULT_BRANCH}" >> $GITHUB_ENV
2930 id : default-branch
3031
31- - name : Extract branch name
32- shell : bash
33- run : echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})"
34- id : extract-branch
35-
3632 - name : " Build DISCVR"
3733 uses : bimberlabinternal/DevOps/githubActions/discvr-build@master
3834 with :
@@ -42,14 +38,14 @@ jobs:
4238 github_token : ${{ secrets.PAT }}
4339 env :
4440 # Only generate the distribution if this is the default branch
45- GENERATE_DIST : ${{ steps.default-branch.branch == steps.extract-branch.branch && '1' || '0' }}
41+ GENERATE_DIST : ${{ env.DEFAULT_BRANCH == github.ref_name && '1' || '0' }}
4642
4743 - name : Publish Release
48- if : github.ref == '/refs/heads/ ${{ fromJson(steps.get_default_branch.outputs.data).default_branch }}' && github.event_name == 'push' && github.base_ref == ''
44+ if : ${{ env.DEFAULT_BRANCH == github.ref_name && github.event_name == 'push' && github.base_ref == '' }}
4945 uses : " marvinpinto/action-automatic-releases@latest"
5046 with :
5147 repo_token : " ${{ secrets.PAT }}"
5248 automatic_release_tag : " latest"
5349 prerelease : true
54- title : " Development Build: ${{ fromJson(steps.get_default_branch.outputs.data).default_branch }}"
50+ title : " Development Build: ${{ env.DEFAULT_BRANCH }}"
5551 files : /home/runner/work/_temp/_github_home/lkDist/discvr/DISCVR-*
0 commit comments