I need to return the path of folder configured via the --with-config-file-scan-dir switch for a particular PHP implementation.
I can achieve this by writing bash code something like:
folder=$(php --ini \
| grep "Scan for additional .ini files in:" \
| cut -d" " -f7 \
)
But the above approach seems inexact and potentially error prone.
My preference would be to do something like the following:
folder=$(php -r 'print ini_get("with-config-file-scan-dir config option");')
but I can't seem to find the necessary configuration option name.
I would greatly appreciate some guru input on this if you have it!
thanks in advance