---
name: lint

"on":
  pull_request:
  push:
    branches:
      - main

jobs:
  chefstyle:
    runs-on: ubuntu-latest
    env:
      BUNDLE_WITHOUT: ruby_shadow:omnibus_package
    steps:
    - uses: actions/checkout@v2
    - uses: ruby/setup-ruby@v1
      with:
        ruby-version: 3.1
        bundler-cache: false
    - uses: r7kamura/rubocop-problem-matchers-action@v1 # this shows the failures in the PR
    - run: |
        gem install chefstyle
        chefstyle -c .rubocop.yml

  spellcheck:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - uses: carlosperate/download-file-action@v1.0.3
        id: download-custom-dictionary
        with:
          file-url: 'https://raw.githubusercontent.com/chef/chef_dictionary/main/chef.txt'
          file-name: 'chef_dictionary.txt'
      - uses: zwaldowski/cspell-action@v1
        with:
          config: cspell.json
          paths: "**/*"

---
name: lint

"on":
  pull_request:
  push:
    branches:
      - main

jobs:
  chefstyle:
    runs-on: ubuntu-latest
    env:
      BUNDLE_WITHOUT: ruby_shadow:omnibus_package
    steps:
    - uses: actions/checkout@v2
    - uses: ruby/setup-ruby@v1
      with:
        ruby-version: 3.1
        bundler-cache: false
    - uses: r7kamura/rubocop-problem-matchers-action@v1  # this shows the failures in the PR
    - run: |
        gem install chefstyle
        chefstyle -c .rubocop.yml

  spellcheck:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - uses: carlosperate/download-file-action@v1.0.3
        id: download-custom-dictionary
        with:
          file-url: 'https://raw.githubusercontent.com/chef/chef_dictionary/main/chef.txt'
          file-name: 'chef_dictionary.txt'
      - uses: zwaldowski/cspell-action@v1
        with:
          config: cspell.json
          paths: "**/*"

Add space before YAML comment
Add space before YAML comment

This conforms more closely to default linting behavior for YAML requiring 2 spaces before inline comments. https://yamllint.readthedocs.io/en/latest/rules.html#module-yamllint.rules.comments

Signed-off-by: Gene Wood <554b3cd6285944658d6dcd5ab0d58c8e35cd6701@cementhorizon.com>
