Skip to content

Commit 9f0d289

Browse files
committed
fix NUKE_CERT variables to be case insensitive
1 parent bafb750 commit 9f0d289

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

.github/workflows/create_certs.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,8 @@ jobs:
6363
id: set_output
6464
run: |
6565
CERT_STATUS_FILE="${{ github.workspace }}/fastlane/new_certificate_needed.txt"
66-
ENABLE_NUKE_CERTS=${{ vars.ENABLE_NUKE_CERTS }}
66+
ENABLE_NUKE_CERTS=$(echo "${{ vars.ENABLE_NUKE_CERTS }}" | tr '[:upper:]' '[:lower:]')
67+
FORCE_NUKE_CERTS=$(echo "${{ vars.FORCE_NUKE_CERTS }}" | tr '[:upper:]' '[:lower:]')
6768
6869
if [ -f "$CERT_STATUS_FILE" ]; then
6970
CERT_STATUS=$(cat "$CERT_STATUS_FILE" | tr -d '\n' | tr -d '\r') # Read file content and strip newlines
@@ -82,8 +83,8 @@ jobs:
8283
echo "::error::❌ No valid distribution certificate found. Automated renewal of certificates was skipped because the repository variable ENABLE_NUKE_CERTS is not set to 'true'."
8384
exit 1
8485
fi
85-
# Check if vars.FORCE_NUKE_CERTS is not set to true
86-
if [ vars.FORCE_NUKE_CERTS = "true" ]; then
86+
# Check if FORCE_NUKE_CERTS is set to true
87+
if [ "$FORCE_NUKE_CERTS" = "true" ]; then
8788
echo "::warning::‼️ Nuking of certificates was forced because the repository variable FORCE_NUKE_CERTS is set to 'true'."
8889
fi
8990
# Nuke Certs if needed, and if the repository variable ENABLE_NUKE_CERTS is set to 'true', or if FORCE_NUKE_CERTS is set to 'true', which will always force certs to be nuked

0 commit comments

Comments
 (0)