Skip to content

Docs12110/metric discrepancy info #33934

Docs12110/metric discrepancy info

Docs12110/metric discrepancy info #33934

Workflow file for this run

name: Vale
on:
pull_request:
paths:
- 'content/en/**/*'
- 'layouts/shortcodes/**/*.md'
- '!**/*.json'
permissions:
contents: read
# Stop the current running job if a new push is made to the PR
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true
jobs:
vale:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
- name: Clone Datadog Vale
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
repository: DataDog/datadog-vale
path: datadog-vale
persist-credentials: false
- uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
with:
python-version: '3.11'
- run: pip install vale==3.9.1
- name: Edit StylesPath in Vale config file
run: sed -i 's/\.\.\/datadog-vale\/styles/datadog-vale\/styles/' .vale.ini
- name: Find changed lines
id: changed_lines
uses: hestonhoffman/changed-lines@b51e5eff3b7f56b60460c5371206e1d781ffa6ab # v1.9.0
with:
file_filter: '.md, .html'
- name: Run vale on changed files
if: steps.changed_lines.outputs.changed_files
env:
CHANGED_FILES: ${{ steps.changed_lines.outputs.changed_files }}
run: |
vale "${CHANGED_FILES}" \
--output=local/bin/py/vale/vale_template.tmpl --no-exit > vale_output.log
- name: Parse Vale output
if: steps.changed_lines.outputs.changed_files
env:
CHANGED_LINES: ${{ steps.changed_lines.outputs.changed_lines }}
run: |
python local/bin/py/vale/vale_annotations.py \
--git_data="${CHANGED_LINES}"