38 lines
854 B
YAML
38 lines
854 B
YAML
name: Lint Yaml
|
|
|
|
# **What it does**: This lints our yaml files in the docs repository.
|
|
# **Why we have it**: We want some level of consistent formatting for YAML files.
|
|
# **Who does it impact**: Docs engineering, docs content.
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
push:
|
|
branches:
|
|
- main
|
|
paths:
|
|
- '**/*.yml'
|
|
- '**/*.yaml'
|
|
pull_request:
|
|
paths:
|
|
- '**/*.yml'
|
|
- '**/*.yaml'
|
|
|
|
jobs:
|
|
lint:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Check out repo
|
|
uses: actions/checkout@1e204e9a9253d643386038d443f96446fa156a97
|
|
|
|
- name: Setup node
|
|
uses: actions/setup-node@270253e841af726300e85d718a5f606959b2903c
|
|
with:
|
|
node-version: 16.13.x
|
|
cache: npm
|
|
|
|
- name: Install dependencies
|
|
run: npm ci
|
|
|
|
- name: Run linter
|
|
run: npx prettier -c "**/*.{yml,yaml}"
|