Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add yamllint, fix inconsistencies in yml files #1558

Merged
merged 3 commits into from
Feb 4, 2022

Conversation

himdel
Copy link
Collaborator

@himdel himdel commented Jan 25, 2022

We have a bunch of yaml files now, and I noticed pr-checks.yml is using different indent rules in one half than the other (missed in #1380)

=> adding yamllint,
and fixing a bunch of errors / fixing alignment.


Fixed:

./.github/workflows/i18n.yml
  8:13      warning  too many spaces after colon  (colons)
  22:5      warning  wrong indentation: expected 6 but found 4  (indentation)

./.github/workflows/pr-checks.yml
  32:5      warning  wrong indentation: expected 6 but found 4  (indentation)
  65:5      warning  wrong indentation: expected 6 but found 4  (indentation)

./.github/workflows/deploy-cloud.yml
  62:1      warning  too many blank lines (1 > 0)  (empty-lines)

./.github/workflows/cypress.yml
  12:13     warning  too many spaces after colon  (colons)
  27:5      warning  wrong indentation: expected 6 but found 4  (indentation)


(ignored long lines, on: keys, spaces in [ arrays ], 1 space before # comments, and required --- on the first line)

adding a lint:yaml task to run yamllint,
and a default config ignoring node_modules/, extending the `relaxed` preset, and allowing longer line length

No-Issue
    ./.github/workflows/i18n.yml
      8:13      warning  too many spaces after colon  (colons)
      22:5      warning  wrong indentation: expected 6 but found 4  (indentation)

    ./.github/workflows/pr-checks.yml
      32:5      warning  wrong indentation: expected 6 but found 4  (indentation)
      65:5      warning  wrong indentation: expected 6 but found 4  (indentation)

    ./.github/workflows/deploy-cloud.yml
      62:1      warning  too many blank lines (1 > 0)  (empty-lines)

    ./.github/workflows/cypress.yml
      12:13     warning  too many spaces after colon  (colons)
      27:5      warning  wrong indentation: expected 6 but found 4  (indentation)
yamllint default mode seems to require starting `---`, and +1 indent levels for arrays
balks on on:, spaces in arrays, and comments after one space, overriding those

    ./.yamllint
      1:1       warning  missing document start "---"  (document-start)

    ./.prettierrc.yaml
      1:1       warning  missing document start "---"  (document-start)

    ./.ls-lint.yml
      1:1       warning  missing document start "---"  (document-start)

    ./.github/dependabot.yml
      1:1       warning  missing document start "---"  (document-start)

    ./.github/ISSUE_TEMPLATE/config.yml
      2:1       warning  missing document start "---"  (document-start)
      4:1       error    wrong indentation: expected 2 but found 0  (indentation)

    ./.github/workflows/i18n.yml
      1:1       warning  missing document start "---"  (document-start)
      3:1       warning  truthy value should be one of [false, true]  (truthy)
      8:3       error    wrong indentation: expected 4 but found 2  (indentation)
      17:9      error    wrong indentation: expected 10 but found 8  (indentation)
      22:5      error    wrong indentation: expected 6 but found 4  (indentation)

    ./.github/workflows/pr-checks.yml
      1:1       warning  missing document start "---"  (document-start)
      3:1       warning  truthy value should be one of [false, true]  (truthy)
      5:16      error    too many spaces inside brackets  (brackets)
      5:37      error    too many spaces inside brackets  (brackets)
      13:5      error    wrong indentation: expected 6 but found 4  (indentation)
      32:5      error    wrong indentation: expected 6 but found 4  (indentation)
      65:5      error    wrong indentation: expected 6 but found 4  (indentation)

    ./.github/workflows/update-manifest.yml
      1:1       warning  missing document start "---"  (document-start)
      3:1       warning  truthy value should be one of [false, true]  (truthy)
      4:22      warning  too few spaces before comment  (comments)
      6:16      error    too many spaces inside brackets  (brackets)
      6:40      error    too many spaces inside brackets  (brackets)
      23:5      error    wrong indentation: expected 6 but found 4  (indentation)

    ./.github/workflows/deploy-cloud.yml
      1:1       warning  missing document start "---"  (document-start)
      3:1       warning  truthy value should be one of [false, true]  (truthy)
      4:22      warning  too few spaces before comment  (comments)
      6:16      error    too many spaces inside brackets  (brackets)
      6:70      error    too many spaces inside brackets  (brackets)
      28:5      error    wrong indentation: expected 6 but found 4  (indentation)

    ./.github/workflows/backported-labels.yml
      1:1       warning  missing document start "---"  (document-start)
      3:1       warning  truthy value should be one of [false, true]  (truthy)
      7:16      error    too many spaces inside brackets  (brackets)
      7:27      error    too many spaces inside brackets  (brackets)
      13:5      error    wrong indentation: expected 6 but found 4  (indentation)

    ./.github/workflows/dev-release.yml
      3:1       warning  missing document start "---"  (document-start)
      5:1       warning  truthy value should be one of [false, true]  (truthy)
      6:22      warning  too few spaces before comment  (comments)
      8:16      error    too many spaces inside brackets  (brackets)
      8:25      error    too many spaces inside brackets  (brackets)
      18:24     warning  too few spaces before comment  (comments)
      23:5      error    wrong indentation: expected 6 but found 4  (indentation)

    ./.github/workflows/stable-release.yml
      1:1       warning  missing document start "---"  (document-start)
      4:1       warning  truthy value should be one of [false, true]  (truthy)
      7:5       error    wrong indentation: expected 6 but found 4  (indentation)
      23:5      error    wrong indentation: expected 6 but found 4  (indentation)

    ./.github/workflows/cypress.yml
      1:1       warning  missing document start "---"  (document-start)
      3:1       warning  truthy value should be one of [false, true]  (truthy)
      7:16      error    too many spaces inside brackets  (brackets)
      7:37      error    too many spaces inside brackets  (brackets)
      9:16      error    too many spaces inside brackets  (brackets)
      9:37      error    too many spaces inside brackets  (brackets)
      12:3      error    wrong indentation: expected 4 but found 2  (indentation)
      27:5      error    wrong indentation: expected 6 but found 4  (indentation)
@himdel himdel merged commit cebb0f6 into ansible:master Feb 4, 2022
@himdel himdel deleted the yamllint branch February 4, 2022 17:09
himdel added a commit to himdel/ansible-hub-ui that referenced this pull request Aug 29, 2022
himdel added a commit that referenced this pull request Sep 1, 2022
* cypress.yml - backport changes from master

Backports cypress.yml changes from #2480, #2478, non-signing parts of #2240, #1979, #2233, #1827, #1558, #1562, #1323

No-Issue

* build from pulp-ci-centos 3.15, not latest (current 4.4 uses pulpcore==3.15.8)

* galaxykit collection list -> namespace list

collection list doesn't exist in 0.7.0 yet (also #2265)

* pulpPrefix - set to /pulp/api/v3/

not API_BASE_PATH + /pulp/api/v3/ .. that's 4.6+

(also reformat, but skip the rest of #1651)

* update cache key
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants