File tree Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change 25
25
26
26
- name : Set version (PR)
27
27
if : ${{ github.event_name == 'pull_request' }}
28
+ env :
29
+ PR_HEAD_REF : " ${{ github.event.pull_request.head.ref }}"
28
30
run : |
29
- echo REF_NAME="${{ github.event.pull_request.head.ref }} " >> $GITHUB_ENV
31
+ echo REF_NAME="$PR_HEAD_REF " >> $GITHUB_ENV
30
32
echo SHA="${{ github.event.pull_request.head.sha }}" >> $GITHUB_ENV
31
33
32
34
- name : Set env variables (Branch/Tag)
Original file line number Diff line number Diff line change 42
42
43
43
- name : Version output
44
44
id : version-output
45
+ env :
46
+ BRANCH : " ${{ github.head_ref || github.ref_name }}"
45
47
run : |
46
48
if [ -z ${{ inputs.version }} ]; then
47
- BRANCH=${{ github.head_ref || github.ref_name }}
48
49
VERSION=0.2.0-${BRANCH/\//-}.${{ github.run_number }}
49
50
echo "version=$VERSION" >> $GITHUB_OUTPUT
50
51
else
You can’t perform that action at this time.
0 commit comments