mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-12-01 03:17:53 -05:00
12 lines
251 B
Ruby
12 lines
251 B
Ruby
|
module OmnibusChecker
|
||
|
def is_omnibus?
|
||
|
Gem.bindir =~ %r{/opt/(opscode|chef)/}
|
||
|
end
|
||
|
end
|
||
|
|
||
|
OmnibusChecker.send(:extend, OmnibusChecker)
|
||
|
|
||
|
unless(Chef::Recipe.instance_methods.include?(:is_omnibus?))
|
||
|
Chef::Recipe.send(:include, OmnibusChecker)
|
||
|
end
|