<commit_before># -*- coding: utf-8 -*-
# vim: ft=jinja

{## Start with  defaults from defaults.sls ##}
{% import_yaml 'template/defaults.yaml' as default_settings %}

{## 
Setup variable using grains['os_family'] based logic, only add key:values here
that differ from whats in defaults.yaml
##}
{% set os_family_map = salt['grains.filter_by']({
        'Debian': {},
        'Suse': {},
        'Arch': {
            "pkg" : 'template-arch',
        },
        'RedHat': {
            "config": '/etc/template.conf',
        },
  }
  , grain="os_family"
  , merge=salt['pillar.get']('template:lookup'))
%}
{## Merge the flavor_map to the default settings ##}
{% do default_settings.template.update(os_family_map) %}

{## Merge in template:lookup pillar ##}
{% set template = salt['pillar.get'](
        'template',
        default=default_settings.template,
        merge=True
    )
%}<commit_msg>create useable values in map.jinja<commit_after># -*- coding: utf-8 -*-
# vim: ft=jinja

{## Start with  defaults from defaults.sls ##}
{% import_yaml 'template/defaults.yaml' as default_settings %}

{## 
Setup variable using grains['os_family'] based logic, only add key:values here
that differ from whats in defaults.yaml
##}
{% set os_family_map = salt['grains.filter_by']({
        'Debian': {
            "sysconfdir" : '/etc/default',
        },
        'RedHat': {
            "sysconfdir": '/etc/sysconf',
        },
  }
  , grain="os_family"
  , merge=salt['pillar.get']('template:lookup'))
%}
{## Merge the flavor_map to the default settings ##}
{% do default_settings.template.update(os_family_map) %}

{## Merge in template:lookup pillar ##}
{% set template = salt['pillar.get'](
        'template',
        default=default_settings.template,
        merge=True
    )
%}
{'fraction_non_alphanumeric': 0.16582349634626195, 'fraction_numerical': 0.0011242270938729624, 'mean_word_length': 3.1203703703703702, 'pattern_counts': {'":': 2, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1025364', 'n_tokens_mistral': 600, 'n_tokens_neox': 575, 'n_words': 126}