Created
September 22, 2011 17:28
-
-
Save ukd1/1235405 to your computer and use it in GitHub Desktop.
PHP Ext directory fact
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Facter.add(:phpextdir) do | |
setcode do | |
if File.exist?('/usr/bin/php') | |
%x{/usr/bin/php -i 2> /dev/null | /usr/bin/awk '/extension_dir/ {print $3}'}.chomp | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment