Here's how you check if a environment variable was set using a bash script:
#!/bin/bash
if [ -z "$AWS_ACCESS_KEY_ID" ]; then
echo "You need to set AWS credentials! Check out the project documentation."
exit;
fi
This script is working on macOS Catalina.
Top comments (0)