Skip to content

fix(scripts): use portable lowercase in normalize_bool for Bash 3.2#1493

Merged
TaylorMutch merged 1 commit into
NVIDIA:mainfrom
benoitf:OPENSHELL-1485
May 21, 2026
Merged

fix(scripts): use portable lowercase in normalize_bool for Bash 3.2#1493
TaylorMutch merged 1 commit into
NVIDIA:mainfrom
benoitf:OPENSHELL-1485

Conversation

@benoitf
Copy link
Copy Markdown
Contributor

@benoitf benoitf commented May 21, 2026

Summary

  • Fix normalize_bool() in gateway-vm.sh and package-snap.sh to use portable lowercase via printf/tr instead of Bash 4+ ${1,,} syntax
  • macOS ships Bash 3.2 which does not support ${1,,}, causing mise run gateway:vm to fail immediately with bad substitution
  • Matches the existing portable pattern already used in gateway.sh

Related Issue

fixes #1485

Changes

  • tasks/scripts/gateway-vm.sh: Replace case "${1,,}" with a local variable lowered via tr '[:upper:]' '[:lower:]'
  • tasks/scripts/package-snap.sh: Same fix

Testing

  • mise run pre-commit passes
  • Unit tests added/updated
  • E2E tests added/updated (if applicable)

Checklist

  • Follows Conventional Commits
  • Commits are signed off (DCO)
  • Architecture docs updated (if applicable)

Replace ${1,,} (Bash 4+) with printf/tr to fix "bad substitution" on
macOS stock Bash 3.2, matching the existing pattern in gateway.sh.

fixes NVIDIA#1485

Signed-off-by: Florent Benoit <fbenoit@redhat.com>
@copy-pr-bot
Copy link
Copy Markdown

copy-pr-bot Bot commented May 21, 2026

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@TaylorMutch
Copy link
Copy Markdown
Collaborator

/ok to test be8b020

@TaylorMutch TaylorMutch merged commit b93a3d8 into NVIDIA:main May 21, 2026
35 of 37 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

gateway-vm.sh fails on macOS stock Bash 3.2 — bad substitution

3 participants