tasks/00_utils.rake
# Utility method to return the dist method if this is a redhat box. We use this
# in rpm packaging to define a dist macro, and we use it in the pl:fetch task
# to disable ssl checking for redhat 5 because it has a certs bundle so old by
# default that it's useless for our purposes.
Utility method to return the dist method if this is a redhat box. We use this
in rpm packaging to define a dist macro, and we use it in the pl:fetch task
to disable ssl checking for redhat 5 because it has a certs bundle so old by
default that it's useless for our purposes.
Utility method to return the dist method if this is a redhat box . We use this in rpm packaging to define a dist macro and we use it in the pl : fetch task to disable ssl checking for redhat 5 because it has a certs bundle so old by default that it ' s useless for our purposes .
def el_version
  if File.exists?('/etc/fedora-release')
    nil
  elsif File.exists?('/etc/redhat-release')
    return %x{rpm -q --qf \"%{VERSION}\" $(rpm -q --whatprovides /etc/redhat-release )}
  end
end
def el_version if File . exists? ( '/etc/fedora-release' ) nil elsif File . exists? ( '/etc/redhat-release' ) return %x{ rpm -q --qf  \" %{VERSION} \"  $(rpm -q --whatprovides /etc/redhat-release ) } end end
Utility method to return the dist method if this is a redhat box.
Utility method to return the dist method if this is a redhat box .