HEX
Server: Apache
System: Linux vps28526 6.8.0-79-generic #79~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Aug 15 16:54:53 UTC 2 x86_64
User: heewonvps_17 (6705002)
PHP: 7.4.33
Disabled: NONE
Upload Files
File: //usr/local/wp/utils/find-php
#!/usr/bin/env sh

# Special case for *AMP installers, since they normally don't set themselves
# as the default cli php out of the box.
for amp_php in $(cat $(dirname $0)/amp-paths.txt); do
	if [ -x $amp_php ]; then
		echo $amp_php
		exit
	fi
done

which php || which php-cli

if [ $? -eq 0 ]; then
	exit
fi

echo "no PHP binary found" >&2
exit 1