Class: Facts::Archlinux::Os::Release
- Inherits:
-
Object
- Object
- Facts::Archlinux::Os::Release
- Defined in:
- lib/facter/facts/archlinux/os/release.rb
Constant Summary collapse
- FACT_NAME =
'os.release'
Instance Method Summary collapse
Instance Method Details
#call_the_resolver ⇒ Object
9 10 11 12 13 14 15 16 17 |
# File 'lib/facter/facts/archlinux/os/release.rb', line 9 def call_the_resolver # Arch Linux is rolling release and has no version numbers # For historical reasons facter used the kernel version as OS version on Arch Linux kernelrelease = Facter::Resolvers::Uname.resolve(:kernelrelease) versions = kernelrelease.split('.') hash = { full: kernelrelease, major: versions[0], minor: versions[1] } Facter::ResolvedFact.new(FACT_NAME, hash) end |