Merge pull request #27530 from SaltyCharles/add-osfinger-osmajor-osx-grains

add osfinger and osmajorrelease to osx grains
This commit is contained in:
Mike Place 2015-09-30 09:18:37 -06:00
commit d78e14002c

View File

@ -1388,6 +1388,12 @@ def os_data():
grains['osfinger'] = '{os}-{ver}'.format(
os=grains['os'],
ver=grains['osrelease'])
elif grains.get('os') in 'MacOS':
grains['osmajorrelease'] = grains['osrelease'].split('.', 1)[0]
grains['osfinger'] = '{os}-{ver}'.format(
os=grains['os'],
ver=grains['osrelease'].rsplit('.', 1)[0])
if grains.get('osrelease', ''):
osrelease_info = grains['osrelease'].split('.')