Skip to content

docs: align built-in rules docs with the actual code #1196

docs: align built-in rules docs with the actual code

docs: align built-in rules docs with the actual code #1196

Workflow file for this run

name: Pre-release Checks
permissions:
contents: read
pull-requests: write
on:
pull_request:
branches:
- main
env:
CI: true
REDOCLY_TELEMETRY: off
jobs:
checks:
# Run only on release branch (changeset-release/main):
if: github.head_ref == 'changeset-release/main'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0
with:
node-version: 24
- name: Check Redocly Config Version
run: |
LATEST_VERSION=$(npm view @redocly/config version)
CURRENT_VERSION=$(jq -r '.dependencies["@redocly/config"] | ltrimstr("^") | ltrimstr("~")' packages/core/package.json)
echo Latest: $LATEST_VERSION, Current: $CURRENT_VERSION
if [ "$LATEST_VERSION" != "$CURRENT_VERSION" ]; then
COMMENT="⚠️ **Redocly Config version mismatch**: The latest published version of \`@redocly/config\` is \`$LATEST_VERSION\`, but the current version is \`$CURRENT_VERSION\`. Please consider updating to the latest version."
echo "$COMMENT"
gh pr comment $PR_NUMBER --body "$COMMENT"
exit 1
else
echo "Redocly Config version is up to date: $CURRENT_VERSION"
fi
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PR_NUMBER: ${{ github.event.pull_request.number }}