From e671aa4aa87ca10016f49cd500721ae00032b722 Mon Sep 17 00:00:00 2001 From: Erik Michelson Date: Sun, 30 Jan 2022 21:57:58 +0100 Subject: [PATCH] Fix netlify not using aliases containing a slash (#1819) --- .github/workflows/deploy.yml | 2 +- netlify/deploy.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 100316546..7c864d485 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -56,7 +56,7 @@ jobs: - name: Run netlify CLI deployment env: NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }} - run: bash netlify/deploy.sh "${{ github.event.number }}" "${{ github.head_ref }}" "${{ github.event.pull_request.title }}" + run: bash netlify/deploy.sh "${{ github.event.number }}" "${{ github.event.pull_request.title }}" id: netlify-result - name: Mark GitHub deployment as finished diff --git a/netlify/deploy.sh b/netlify/deploy.sh index f627852d5..fe884b9cf 100755 --- a/netlify/deploy.sh +++ b/netlify/deploy.sh @@ -4,9 +4,9 @@ # # SPDX-License-Identifier: AGPL-3.0-only -deployid="$1-$2" +json=$(yarn netlify deploy --build --context deploy-preview --alias "$1" --json --message "[#$1] $2") -json=$(yarn netlify deploy --build --context deploy-preview --alias "${deployid}" --json --message "[#$1] $3") +echo "${json}" url=$(echo "${json}" | jq -r .deploy_url) logs=$(echo "${json}" | jq -r .logs)