Package: facter
Version: 1.3.7-1
Severity: minor
adds 4.0/etch support
adds lenny/sid support (it reports "sid")
jump out of the loop if we match
Adrian
--
Email: [EMAIL PROTECTED] -*- GPG key available on public key servers
Debian GNU/Linux - the maintainable distribution -*- www.debian.org
Avoid working with children, animals and Microsoft "operating" systems
#
# This scriptlet loads the releasename for the local Debianverison
#
require 'thread'
DEBIAN_RELEASES = {
'3.0' => 'woody',
'3.1' => 'sarge',
'4.0' => 'etch',
'lenny/sid' => 'sid',
'testing/unstable' => 'sid',
}
if Facter.operatingsystem == "Debian"
Thread::exclusive do
debian_version = ""
File.readlines("/etc/debian_version").each do |l|
debian_version = DEBIAN_RELEASES[l.strip]
break if debian_version
end
Facter.add("Debianversion") do
setcode do
debian_version
end
end
end
end