From 304b199b700f130925c09c330a63fc6c4745321b Mon Sep 17 00:00:00 2001 From: mh Date: Sat, 31 Oct 2009 15:16:40 +0100 Subject: move plugin directory to fit new 0.25 style --- lib/facter/mysql.rb | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 lib/facter/mysql.rb (limited to 'lib/facter/mysql.rb') diff --git a/lib/facter/mysql.rb b/lib/facter/mysql.rb new file mode 100644 index 0000000..e262ec1 --- /dev/null +++ b/lib/facter/mysql.rb @@ -0,0 +1,8 @@ +Facter.add("mysql_exists") do + ENV["PATH"]="/bin:/sbin:/usr/bin:/usr/sbin" + + setcode do + mysqlexists = system "which mysql > /dev/null 2>&1" + ($?.exitstatus == 0) + end +end -- cgit v1.2.3