def auto(name):
 ret = {'name': name, 'result': True, 'comment': '', 'changes': {}}
 display = __salt__['alternatives.display'](name)
 line = display.splitlines()[0]
 if line.endswith(' auto mode'):
  ret['comment'] = '{0} already in auto mode'.format(name)
  return ret
 if __opts__['test']:
  ret['comment'] = '{0} will be put in auto mode'.format(name)
  ret['result'] = None
  return ret
 ret['changes']['result'] = __salt__['alternatives.auto'](name)
 return ret

def auto ( name ) : ret = { 'name' : name , 'result' : True , 'comment' : '' , 'changes' : { } } display = __salt__ [ 'alternatives.display' ] ( name ) line = display . splitlines ( ) [ 0 ] if line . endswith ( ' auto mode' ) : ret [ 'comment' ] = '{0} already in auto mode' . format ( name ) return ret if __opts__ [ 'test' ] : ret [ 'comment' ] = '{0} will be put in auto mode' . format ( name ) ret [ 'result' ] = None return ret ret [ 'changes' ] [ 'result' ] = __salt__ [ 'alternatives.auto' ] ( name ) return ret
fix pep8 erorrs in current buffer .