updated scripts

This commit is contained in:
reynold
2025-08-28 15:51:17 +08:00
parent b09cbed174
commit a385484a69
9 changed files with 1503 additions and 12 deletions

View File

@@ -50,6 +50,26 @@ while getopts ":o:p:Uh" opt; do
esac
done
# Silent environment check - verify SF CLI is available
if ! command -v sf >/dev/null 2>&1; then
echo "❌ Salesforce CLI (sf) not found!"
echo
echo "Running environment check to help you get started..."
echo
# Try to find and run sf-check in the same directory as this script
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
if [[ -x "$SCRIPT_DIR/sf-check" ]]; then
"$SCRIPT_DIR/sf-check"
elif command -v sf-check >/dev/null 2>&1; then
sf-check
else
echo "sf-check not found. Please install the Salesforce CLI from:"
echo "https://developer.salesforce.com/tools/sfdxcli"
fi
exit 1
fi
CMD=(sf org open)
[[ -n "$ORG" ]] && CMD+=(--target-org "$ORG")