Skip to content

Commit 03fccc4

Browse files
style: re-enable cmake-format JSON formatter (#5210)
#4467 disabled the JSON formatter. Now it is turned on again, but ignores files added by #4467. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Chores** * Refined formatting configuration to apply formatter to more JSON files (narrower exclusions). * Reformatted JSON content for readability without changing any data or behavior. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Signed-off-by: Jinzhe Zeng <jinzhe.zeng@ustc.edu.cn> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent 9465d71 commit 03fccc4

2 files changed

Lines changed: 18 additions & 7 deletions

File tree

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ repos:
6363
rev: v21.1.8
6464
hooks:
6565
- id: clang-format
66-
exclude: ^(source/3rdparty|source/lib/src/gpu/cudart/.+\.inc|.+\.ipynb$|.+\.json$)
66+
exclude: ^(source/3rdparty|source/lib/src/gpu/cudart/.+\.inc|.+\.ipynb$|source/tests/infer/.+\.json$)
6767
# markdown, yaml, CSS, javascript
6868
- repo: https://github.com/pre-commit/mirrors-prettier
6969
rev: v4.0.0-alpha.8

examples/water_multi_task/pytorch_example/input_torch_with_alias.json

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -58,20 +58,31 @@
5858
"type_map": "type_map_all",
5959
"descriptor": "dpa3_descriptor",
6060
"fitting_net": "shared_fit_with_id",
61-
"model_branch_alias": ["Default","Water"],
61+
"model_branch_alias": [
62+
"Default",
63+
"Water"
64+
],
6265
"info": {
63-
"description": "Water model with DPA3 descriptor and shared fitting net",
64-
"observed_type": ["H", "O"]
66+
"description": "Water model with DPA3 descriptor and shared fitting net",
67+
"observed_type": [
68+
"H",
69+
"O"
70+
]
6571
}
6672
},
6773
"water_2": {
6874
"type_map": "type_map_all",
6975
"descriptor": "dpa3_descriptor",
7076
"fitting_net": "shared_fit_with_id",
71-
"model_branch_alias": ["Water2"],
77+
"model_branch_alias": [
78+
"Water2"
79+
],
7280
"info": {
73-
"description": "Water duplicated model with DPA3 descriptor and shared fitting net",
74-
"observed_type": ["H", "O"]
81+
"description": "Water duplicated model with DPA3 descriptor and shared fitting net",
82+
"observed_type": [
83+
"H",
84+
"O"
85+
]
7586
}
7687
}
7788
}

0 commit comments

Comments
 (0)