From de42d134a4484fd98fcc65865eacd346f25d0786 Mon Sep 17 00:00:00 2001 From: AbstractionFactory <179820029+abstractionfactory@users.noreply.github.com> Date: Thu, 21 Nov 2024 11:25:34 +0100 Subject: [PATCH] Shellcheck workaround Signed-off-by: AbstractionFactory <179820029+abstractionfactory@users.noreply.github.com> --- .github/scripts/submit-module.sh | 2 +- .github/scripts/submit-provider.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/scripts/submit-module.sh b/.github/scripts/submit-module.sh index 22ed78c7fa..c72e89b642 100755 --- a/.github/scripts/submit-module.sh +++ b/.github/scripts/submit-module.sh @@ -17,7 +17,7 @@ if [[ -z "${NUMBER}" ]]; then fi repository=$(echo "${BODY}" | grep "### Module Repository" -A2 | tail -n1 | tr "[:upper:]" "[:lower:]" | sed -e 's/[\r\n]//g') -repository=$(echo -n "${repository}" | sed -e 's$https://github.com/$$' -e 's$github.com/$$') +repository=$(echo -n "${repository}" | sed -e 's|https://github.com/||' -e 's|github.com/||') if [[ ! "${repository}" =~ ^[a-zA-Z0-9-]+/terraform-[a-zA-Z0-9-]+$ ]]; then gh issue comment "${NUMBER}" -b "Failed validation: Invalid repository name: '${repository}'. Please edit your issue to state the name of the repository in the format of ORGANIZATION/terraform-NAME-TARGETSYSTEM." diff --git a/.github/scripts/submit-provider.sh b/.github/scripts/submit-provider.sh index 86d72dfda8..04b1703b7d 100755 --- a/.github/scripts/submit-provider.sh +++ b/.github/scripts/submit-provider.sh @@ -17,7 +17,7 @@ if [[ -z "${NUMBER}" ]]; then fi repository=$(echo "${BODY}" | grep "### Provider Repository" -A2 | tail -n1 | tr "[:upper:]" "[:lower:]" | sed -e 's/[\r\n]//g') -repository=$(echo -n "${repository}" | sed -e 's$https://github.com/$$' -e 's$github.com/$$') +repository=$(echo -n "${repository}" | sed -e 's|https://github.com/||' -e 's|github.com/||') if [[ ! "${repository}" =~ ^[a-zA-Z0-9-]+/terraform-provider-[a-zA-Z0-9-]+$ ]]; then gh issue comment "${NUMBER}" -b "Failed validation: Invalid repository name: '${repository}'. Please edit your issue to state the repository in the format of ORGANIZATION/terraform-provider-NAME."