Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ jobs:
- '!ci/release/**'
- '!ci/run_*.pytests.sh'
- '!ci/run_ctests.sh'
- '!ci/run-vale.sh'
- '!ci/test_cpp*.sh'
- '!ci/test_notebooks.sh'
- '!ci/test_python.sh'
Expand Down Expand Up @@ -173,6 +174,7 @@ jobs:
- '!ci/check_style.sh'
- '!ci/docker/**'
- '!ci/release/**'
- '!ci/run-vale.sh'
- '!ci/test_python.sh'
- '!ci/test_self_hosted_service.sh'
- '!ci/test_wheel*.sh'
Expand Down Expand Up @@ -243,6 +245,7 @@ jobs:
- '!ci/check_style.sh'
- '!ci/docker/**'
- '!ci/release/**'
- '!ci/run-vale.sh'
- '!ci/test_self_hosted_service.sh'
- '!ci/test_wheel*.sh'
- '!ci/thirdparty-testing/**'
Expand Down Expand Up @@ -313,6 +316,7 @@ jobs:
- '!ci/docker/**'
- '!ci/release/**'
- '!ci/run_ctests.sh'
- '!ci/run-vale.sh'
- '!ci/test_python.sh'
- '!ci/thirdparty-testing/**'
- '!ci/utils/sync_skills_version.sh'
Expand Down
8 changes: 7 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -137,8 +137,14 @@ repos:
files: ^(VERSION|\.claude-plugin/marketplace\.json|\.cursor-plugin/plugin\.json|gemini-extension\.json)$
- id: vale
name: Vale docs prose lint
entry: vale
entry: ci/run-vale.sh
verbose: true
language: system
# 'pass_filenames: false' prevents pre-commit from invoking 'vale' once per file,
# (instead passes all files at once to 1 invocation)
pass_filenames: false
Comment thread
coderabbitai[bot] marked this conversation as resolved.
args: [--output=line, --minAlertLevel=warning, docs/cuopt/source]
# needs to be kept in sync with vale.ini
files: ^docs/cuopt/source/.*\.(rst|md)$
- id: validate-skills
name: Validate agent skills
Expand Down
17 changes: 17 additions & 0 deletions ci/run-vale.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/bash

# SPDX-FileCopyrightText: Copyright (c) 2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
# SPDX-License-Identifier: Apache-2.0

set -euo pipefail

if ! command -v vale &>/dev/null; then
if [[ "${CI:-}" != "true" ]]; then
echo "WARNING: vale not found — skipping prose lint. Install 'vale' to run this check locally." >&2
exit 0
fi
echo "ERROR: vale not found and CI=true." >&2
exit 1
fi

exec vale "$@"
Comment thread
jameslamb marked this conversation as resolved.