Skip to content

Commit 45aa5e0

Browse files
authored
Merge pull request kokkos#171 from dssgabriel/feature/pre-commit
2 parents 05cc04b + 41b2dae commit 45aa5e0

File tree

18 files changed

+113
-34
lines changed

18 files changed

+113
-34
lines changed

.clang-format

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ SortIncludes: false
44
AlignConsecutiveAssignments: true
55
AllowShortCaseLabelsOnASingleLine: true
66
AllowShortIfStatementsOnASingleLine: true
7-
ColumnLimit: 120
7+
ColumnLimit: 120

.cmake-format

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
line_length: 120
2+
list_expansion: favour-inlining
3+
indent: 2

.github/workflows/formatting.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ jobs:
2121
- name: Run clang-format style check.
2222
uses: DoozyX/[email protected]
2323
with:
24-
clangFormatVersion: 14
24+
clangFormatVersion: 14

.github/workflows/snl-at2.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: SNL-AT2
22

3-
on:
3+
on:
44
pull_request:
55
paths-ignore:
66
- 'docs/**'

.github/workflows/snl-h100.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
PR_CUDA1250_OPENMPI504:
1212
name: PR_CUDA1250_OPENMPI504
1313
runs-on: [cuda125-openmpi504-latest-latest]
14-
14+
1515
steps:
1616
- name: Checkout Kokkos Comm
1717
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ Testing
55
kokkos
66
docs/_build
77
.python-version
8-
.venv
8+
.venv

.pre-commit-config.yaml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# See https://pre-commit.com for more information
2+
# See https://pre-commit.com/hooks.html for more hooks
3+
repos:
4+
- repo: https://github.com/pre-commit/pre-commit-hooks
5+
rev: v6.0.0
6+
hooks:
7+
- id: trailing-whitespace
8+
name: Trim trailing white space
9+
- id: end-of-file-fixer
10+
name: Fix EOFs
11+
- id: check-yaml
12+
name: Check YAML files
13+
- id: check-added-large-files
14+
name: Check adding large files
15+
16+
# C++ formatting with clang-format
17+
- repo: https://github.com/pre-commit/mirrors-clang-format
18+
rev: v14.0.6
19+
hooks:
20+
- id: clang-format
21+
name: Format C++ files
22+
types_or: [c++, c]
23+
exclude: ^docs/ # do not format any C++ files in the documentation
24+
25+
# CMake formatting with gersemi
26+
- repo: https://github.com/BlankSpruce/gersemi
27+
rev: 0.22.2
28+
hooks:
29+
- id: gersemi
30+
name: Format CMake files
31+
args: ["--config=.cmake-format"]
32+
33+
# Spell-checking
34+
- repo: https://github.com/crate-ci/typos
35+
rev: v1.36.2
36+
hooks:
37+
- id: typos
38+
name: Spell-check for typos

.typos.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
[default.extend-words]
22
# Don't correct these word (parts)
3-
arange = "arange"
3+
arange = "arange"

LICENSE

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
************************************************************************
2-
2+
33
Kokkos v. 4.0
44
Copyright (2022) National Technology & Engineering
55
Solutions of Sandia, LLC (NTESS).
6-
6+
77
Under the terms of Contract DE-NA0003525 with NTESS,
88
the U.S. Government retains certain rights in this software.
99

@@ -231,7 +231,7 @@
231231
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
232232
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
233233

234-
Questions? Contact:
234+
Questions? Contact:
235235
Carl Pearson ([email protected]) and/or
236236
Jan Ciesko ([email protected]) and/or
237237
Cedric Chevalier ([email protected])

cmake/KokkosComm_config.hpp.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,4 @@
2626

2727
#if defined(KOKKOSCOMM_ENABLE_MPI) && __has_include(<mpi-ext.h>)
2828
#define KOKKOSCOMM_IMPL_MPIEXT_H
29-
#endif
29+
#endif

0 commit comments

Comments
 (0)