diff --git a/.github/workflows/deploy-preview.yml b/.github/workflows/deploy-preview.yml index 2f8f7ab6..b5d4d993 100644 --- a/.github/workflows/deploy-preview.yml +++ b/.github/workflows/deploy-preview.yml @@ -34,13 +34,13 @@ jobs: - name: Extract branch name id: branch - # Extract the branch name and replace `/` with `-`. + # Extract the branch name and replace `/` or `.` with `-`. # ${parameter//pattern/string} # Notice the double `//` to replace all occurrences. run: | echo "Extracting branch name ${{ github.head_ref }}" branch_name=${{ github.head_ref }} - echo "::set-output name=name::$(echo ${branch_name//\//-})" + echo "::set-output name=name::$(echo ${branch_name//[\/|\.]/-})" shell: bash - name: Deploying to surge (preview)