Skip to content

Commit faaaadb

Browse files
authored
Merge pull request #73 from shopware/fix-default-token-auth-in-shopwer-version
fix: only configure auth if token is provided
2 parents 56fc387 + 4a1136d commit faaaadb

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

shopware-version/action.yml

+4-2
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ inputs:
1616
required: false
1717
shopware-github-token:
1818
description: Token used for checking out the shopware repository
19-
required: true
20-
default: ${{ github.token }}
19+
required: false
20+
default: ""
2121

2222
outputs:
2323
shopware-version:
@@ -28,6 +28,7 @@ runs:
2828
using: "composite"
2929
steps:
3030
- shell: bash
31+
if: ${{ inputs.shopware-github-token }}
3132
run: |
3233
git config --global "http.https://github.com/${{ inputs.repo || 'shopware/shopware' }}".extraheader "AUTHORIZATION: basic $(echo -n "x-access-token:${{ inputs.shopware-github-token }}" | base64 -w0)"
3334
@@ -44,5 +45,6 @@ runs:
4445
run: ${GITHUB_ACTION_PATH}/shopware-version.bash
4546

4647
- shell: bash
48+
if: ${{ inputs.shopware-github-token }}
4749
run: |
4850
git config --global --unset "http.https://github.com/${{ inputs.repo || 'shopware/shopware' }}".extraheader

0 commit comments

Comments
 (0)