Fix Ruby versioning in workflow

This commit is contained in:
Wilson Lin 2020-06-19 12:22:28 +10:00
parent a35f1c181c
commit dd78ff226b
1 changed files with 2 additions and 6 deletions

View File

@ -26,9 +26,7 @@ jobs:
- name: Get version
id: version
shell: bash
run: |
v=${GITHUB_REF#refs/tags/v}
echo ::set-output name=VERSION::${v:-0.0.0}
run: echo ::set-output name=VERSION::"$([[ "$GITHUB_REF" == refs/tags/v* ]] && echo ${GITHUB_REF#refs/tags/v} || echo '0.0.0')"
# Install Ruby manually as actions/setup-ruby@v1 does not compile with `--enable-shared`.
- name: Prepare for rbenv
run: |
@ -95,9 +93,7 @@ jobs:
- name: Get version
id: version
shell: bash
run: |
v=${GITHUB_REF#refs/tags/v}
echo ::set-output name=VERSION::${v:-0.0.0}
run: echo ::set-output name=VERSION::"$([[ "$GITHUB_REF" == refs/tags/v* ]] && echo ${GITHUB_REF#refs/tags/v} || echo '0.0.0')"
- name: Set up Ruby
uses: actions/setup-ruby@v1
with: