Skip to content

Add clang-format check GitHub Action for changed C/C++ files - #41

Merged
bibrakc merged 1 commit into
amazon-contributing:stagingfrom
bibrakc:add-clang-format-ci-staging
Jul 30, 2026
Merged

Add clang-format check GitHub Action for changed C/C++ files#41
bibrakc merged 1 commit into
amazon-contributing:stagingfrom
bibrakc:add-clang-format-ci-staging

Conversation

@bibrakc

@bibrakc bibrakc commented Jul 30, 2026

Copy link
Copy Markdown
Collaborator

NVIDIA/nccl upstream runs no GitHub Actions, so this fork has had no automated clang-format enforcement on pull requests. Add a workflow that, on PRs and pushes to master/dev/staging, checks only the added/modified/ renamed .cc/.cu/.cuh/.h files under src/ using clang-format in check mode (--dry-run --Werror). Pre-existing formatting in files a change does not touch never blocks the change.

  • Installs a pinned clang-format 22.1.2 (matches MIN_VERSION in maint/run-clang-format.sh) via pip for a deterministic CI version.
  • Honors the top-level .clang-format-ignore (clang-format skips ignored paths even when listed explicitly).

NVIDIA/nccl upstream runs no GitHub Actions, so this fork has had no
automated clang-format enforcement on pull requests. Add a workflow that,
on PRs and pushes to master/dev/staging, checks only the added/modified/
renamed .cc/.cu/.cuh/.h files under src/ using clang-format in check mode
(--dry-run --Werror). Pre-existing formatting in files a change does not
touch never blocks the change.

- Installs a pinned clang-format 22.1.2 (matches MIN_VERSION in
  maint/run-clang-format.sh) via pip for a deterministic CI version.
- Honors the top-level .clang-format-ignore (clang-format skips ignored
  paths even when listed explicitly).
@bibrakc
bibrakc merged commit c6f4211 into amazon-contributing:staging Jul 30, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant