I used this script since aps-environment existed in iOS but not Catalyst:
entry=$(/usr/libexec/PlistBuddy -c "Print :aps-environment" "$TARGET_TEMP_DIR/$FULL_PRODUCT_NAME.xcent")
if [ "$entry" == "" ]; then
/usr/libexec/PlistBuddy -c "Add :aps-environment string development" "$TARGET_TEMP_DIR/$FULL_PRODUCT_NAME.xcent"
echo "Added aps-environment in $TARGET_TEMP_DIR/$FULL_PRODUCT_NAME.xcent"
else
echo "aps-environment was present in $TARGET_TEMP_DIR/$FULL_PRODUCT_NAME.xcent"
fi
Topic:
App & System Services
SubTopic:
Notifications
Tags: