summaryrefslogtreecommitdiff
path: root/lib/facter/mysql_version.rb
blob: ba3dc36bfc2d7ffe9dea3801cddc5a64a948275c (plain)
1
2
3
4
5
6
Facter.add("mysql_version") do
    confine :mysql_exists => true
    setcode do
        Facter::Util::Resolution.exec('mysql --version').chomp.split(' ')[4].split(',').first
    end
end