# File lib/puppet/provider/service/gentoo.rb, line 26
26:   def enabled?
27:     begin
28:       output = update :show
29:     rescue Puppet::ExecutionFailure
30:       return :false
31:     end
32: 
33:     line = output.split(/\n/).find { |l| l.include?(@resource[:name]) }
34: 
35:     return :false unless line
36: 
37:     # If it's enabled then it will print output showing service | runlevel
38:     if output =~ /^\s*#{@resource[:name]}\s*\|\s*(boot|default)/
39:       return :true
40:     else
41:       return :false
42:     end
43:   end