Skip to content

Commit

Permalink
Check the YAML code in the repo with a linter
Browse files Browse the repository at this point in the history
This check will comment right in the pull request on the lines
which have style violations.

Resolve a few found style violations.

Configure yamllint to skip the 'truthy' check because
otherwise it shows an error on completely fine line 4
in .github/workflows/yaml-lint.yml
  • Loading branch information
NickVolynkin committed Jun 27, 2022
1 parent d9a3c26 commit 4a52957
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 0 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/yaml-lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
---
name: YAML lint

on:
push:
branches:
- '**'
tags-ignore:
- '**'
jobs:
yamllint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2

- name: YAML Lint and Annotate
uses: Staffbase/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
target-path: setup-venv
5 changes: 5 additions & 0 deletions .yamllint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
rules:
truthy: disable
new-lines:
type: unix
1 change: 1 addition & 0 deletions cleanup/action.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
name: 'Clean workspace'
description: 'Clean workspace directory after previous workflow run'
runs:
Expand Down

0 comments on commit 4a52957

Please sign in to comment.