Skip to content

refactor: reading applicationId value from custom application config #2140

refactor: reading applicationId value from custom application config

refactor: reading applicationId value from custom application config #2140

name: Documentation content check
# The `vale` GitHub action does not work on PR events so this is triggered on all pushes.
on: [pull_request]
jobs:
writing_style:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node (uses version in .nvmrc)
uses: actions/setup-node@v3
with:
node-version-file: '.nvmrc'
- name: Download .vale.ini and style rules from @commercetools-docs/writing-style
run: |
package_version=$(node -e "console.log(require('./package.json').dependencies['$PACKAGE_NAME'])")
echo "Removing package.json and pnpm-lock.yaml to avoid installation issues"
rm package.json pnpm-lock.yaml
echo "Installing $PACKAGE_NAME@$package_version"
npm install --no-save "$PACKAGE_NAME@$package_version"
env:
PACKAGE_NAME: '@commercetools-docs/writing-style'
- name: Check content (generates GitHub comments via `reviewdog`)
uses: errata-ai/vale-action@reviewdog
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
files: '["website/src"]'
reporter: github-pr-review
filter_mode: diff_context
fail_on_error: true
vale_flags: '--config=node_modules/@commercetools-docs/writing-style/.vale.ini'
debug: true