Skip to content

Commit

Permalink
fix(salt-lint): fix errors
Browse files Browse the repository at this point in the history
```bash
Examining ssf/libcimatrix.jinja of type state
[204] Lines should be no longer that 160 chars
ssf/libcimatrix.jinja:4
{%- macro format_ci_matrix(platforms, inspec_suites_kitchen, inspec_suites_matrix, platforms_matrix, platforms_matrix_commented_includes, semrel_formula, width=4, use_new_travis_format=False ) %}

[203] Most files should not contain tabs
ssf/libcimatrix.jinja:28
{#-             | #     | inc   | exc   | result |                                                          #}

[203] Most files should not contain tabs
ssf/libcimatrix.jinja:30
{#-             | 1     |  y    | []    |  TRUE  |                                                          #}

[203] Most files should not contain tabs
ssf/libcimatrix.jinja:31
{#-             | 2     |  y    |  n    |  TRUE  |                                                          #}

[203] Most files should not contain tabs
ssf/libcimatrix.jinja:32
{#-             | 3     |  y    |  y    |  TRUE  |                                                          #}

[203] Most files should not contain tabs
ssf/libcimatrix.jinja:33
{#-             | 4     | []    | []    |  TRUE  |                                                          #}

[203] Most files should not contain tabs
ssf/libcimatrix.jinja:34
{#-             | 5     | []    |  n    |  TRUE  |                                                          #}

[203] Most files should not contain tabs
ssf/libcimatrix.jinja:35
{#-             | 6     | []    |  y    | FALSE  |                                                          #}

[203] Most files should not contain tabs
ssf/libcimatrix.jinja:36
{#-             | 7     |  n    | []    | FALSE  |                                                          #}

[203] Most files should not contain tabs
ssf/libcimatrix.jinja:37
{#-             | 8     |  n    |  n    | FALSE  |                                                          #}

[203] Most files should not contain tabs
ssf/libcimatrix.jinja:38
{#-             | 9     |  n    |  y    | FALSE  |                                                          #}

[206] Jinja variables should have spaces before and after: {{ var_name }}
ssf/libcimatrix.jinja:70
{{ comment }}- {{instance_and_env }}{{ instance }}

...

Examining ssf/map.jinja of type state
[209] Jinja comment should have spaces before and after: {# comment #}
ssf/map.jinja:10
{## Merge the formulas ##}
```
  • Loading branch information
myii committed Oct 10, 2019
1 parent 2dac9b0 commit 5890b8a
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 13 deletions.
33 changes: 21 additions & 12 deletions ssf/libcimatrix.jinja
Original file line number Diff line number Diff line change
@@ -1,7 +1,16 @@
# -*- coding: utf-8 -*-
# vim: ft=jinja

{%- macro format_ci_matrix(platforms, inspec_suites_kitchen, inspec_suites_matrix, platforms_matrix, platforms_matrix_commented_includes, semrel_formula, width=4, use_new_travis_format=False ) %}
{%- macro format_ci_matrix(
platforms,
inspec_suites_kitchen,
inspec_suites_matrix,
platforms_matrix,
platforms_matrix_commented_includes,
semrel_formula,
width=4,
use_new_travis_format=False
) %}
{%- filter indent(width) %}
{#- Centralise duplication from here and `kitchen.yml` #}
{%- set platform_and_suite_names_done = [] %}
Expand All @@ -25,17 +34,17 @@
{%- do platform_and_suite_names_done.append(platform_and_suite_name) %}
{#- Only continue depending on an appropriate combination of `includes` and `excludes`: #}
{#- |---|-----|-----|--------| #}
{#- | # | inc | exc | result | #}
{#- | # | inc | exc | result | #}
{#- |---|-----|-----|--------| #}
{#- | 1 | y | [] | TRUE | #}
{#- | 2 | y | n | TRUE | #}
{#- | 3 | y | y | TRUE | #}
{#- | 4 | [] | [] | TRUE | #}
{#- | 5 | [] | n | TRUE | #}
{#- | 6 | [] | y | FALSE | #}
{#- | 7 | n | [] | FALSE | #}
{#- | 8 | n | n | FALSE | #}
{#- | 9 | n | y | FALSE | #}
{#- | 1 | y | [] | TRUE | #}
{#- | 2 | y | n | TRUE | #}
{#- | 3 | y | y | TRUE | #}
{#- | 4 | [] | [] | TRUE | #}
{#- | 5 | [] | n | TRUE | #}
{#- | 6 | [] | y | FALSE | #}
{#- | 7 | n | [] | FALSE | #}
{#- | 8 | n | n | FALSE | #}
{#- | 9 | n | y | FALSE | #}
{#- |---|-----|-----|--------| #}
{%- if (platform in includes) or (not includes and platform not in excludes) %}
{%- set include_instance = True %}
Expand Down Expand Up @@ -67,7 +76,7 @@
salt_ver | replace('.', '-'),
py_ver,
) %}
{{ comment }}- {{instance_and_env }}{{ instance }}
{{ comment }}- {{ instance_and_env }}{{ instance }}
{%- endif %}
{%- endif %}
{%- endif %}
Expand Down
2 changes: 1 addition & 1 deletion ssf/map.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
{%- import_yaml tplroot ~ "/defaults.yaml" as defaults %}
{%- import_yaml tplroot ~ "/formulas.yaml" as formulas %}

{## Merge the formulas ##}
{#- Merge the formulas #}
{%- do salt['defaults.merge'](defaults, formulas) %}

{#- Merge the ssf config (e.g. from pillar) #}
Expand Down

0 comments on commit 5890b8a

Please sign in to comment.