Skip to content

Commit

Permalink
Release v2
Browse files Browse the repository at this point in the history
  • Loading branch information
GrimLink committed Mar 3, 2024
1 parent f861709 commit 30b6c85
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions mage
Original file line number Diff line number Diff line change
Expand Up @@ -635,20 +635,19 @@ case "${@}" in
countries="NL,BE,LU,DE"
fi

if [[ -n "$scope" ]]; then
scope="--scope=stores --scope-code=${scope}"
fi

countries="$(mage_lang_format_arguments $countries)"
country=$(echo "${countries}" | cut -d ',' -f 1 | tr '[:lower:]' '[:upper:]')

echo "scope:$scope - countries:$countries"
$MAGENTO_CLI config:set $scope general/country/default $country
$MAGENTO_CLI config:set $scope general/country/allow $countries

if [[ -z "$scope" ]]; then
$MAGENTO_CLI config:set $scope general/country/destinations $countries
if [[ -n "$scope" ]]; then
echo "Setting the following countries: $countries for $scope"
scope="--scope=stores --scope-code=${scope}"
else
echo "Setting the following countries: $countries"
$MAGENTO_CLI config:set -q general/country/allow $countries
fi

$MAGENTO_CLI config:set -q $scope general/country/default $country
$MAGENTO_CLI config:set -q $scope general/country/destinations $countries
;;

"log" | "log debug")
Expand Down

0 comments on commit 30b6c85

Please sign in to comment.