Skip to content

Commit

Permalink
change the grep to be more inclusive
Browse files Browse the repository at this point in the history
  • Loading branch information
jazzsequence committed Jun 26, 2024
1 parent 635f257 commit 36f32df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion private/scripts/helpers.sh
Original file line number Diff line number Diff line change
Expand Up @@ -484,7 +484,7 @@ function clean_up() {
# Get the themes.
themelist=$(terminus wp -- "$sitename"."$siteenv" theme list --format=csv | tr -d '\n' | tr -d ' ')

if ! echo "$themelist" | grep -w "^sagename"; then
if ! echo "$themelist" | grep -q -E "(^|,)$sagename($|,)"; then
echo "${red}Theme $sagename not found in the theme list. Exiting here.${normal}"
echo "$themelist"
exit 1;
Expand Down

0 comments on commit 36f32df

Please sign in to comment.