Commit ccdd91f9 by Michael DeHaan

Merge pull request #6861 from ericlake/devel

add distribution_major_version to fact gathering
parents 036c8193 7f973619
...@@ -231,6 +231,7 @@ class Facts(object): ...@@ -231,6 +231,7 @@ class Facts(object):
dist = platform.dist() dist = platform.dist()
self.facts['distribution'] = dist[0].capitalize() or 'NA' self.facts['distribution'] = dist[0].capitalize() or 'NA'
self.facts['distribution_version'] = dist[1] or 'NA' self.facts['distribution_version'] = dist[1] or 'NA'
self.facts['distribution_major_version'] = dist[1].split('.')[0] or 'NA'
self.facts['distribution_release'] = dist[2] or 'NA' self.facts['distribution_release'] = dist[2] or 'NA'
# Try to handle the exceptions now ... # Try to handle the exceptions now ...
for (path, name) in Facts.OSDIST_DICT.items(): for (path, name) in Facts.OSDIST_DICT.items():
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment