Skip to content

Commit

Permalink
dont run clang-format on gitattributes
Browse files Browse the repository at this point in the history
  • Loading branch information
teh-cmc committed Oct 17, 2023
1 parent 1836a11 commit cc4bb19
Show file tree
Hide file tree
Showing 10 changed files with 278 additions and 682 deletions.
9 changes: 8 additions & 1 deletion crates/re_types_builder/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,14 @@ pub fn generate_cpp_code(
re_tracing::profile_scope!("write_files");

files.par_iter().for_each(|(filepath, contents)| {
crate::codegen::common::write_file(filepath, &format_code(contents));
// There's more than cpp/hpp files in here, don't run clang-format on them!
let contents =
if filepath.extension() == Some("cpp") || filepath.extension() == Some("hpp") {
format_code(contents)
} else {
contents.clone()
};
crate::codegen::common::write_file(filepath, &contents);
});
}
// 4. Remove orphaned files.
Expand Down
11 changes: 6 additions & 5 deletions rerun_cpp/src/rerun/.gitattributes

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

168 changes: 48 additions & 120 deletions rerun_cpp/src/rerun/archetypes/.gitattributes

Large diffs are not rendered by default.

11 changes: 6 additions & 5 deletions rerun_cpp/src/rerun/blueprint/.gitattributes

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

263 changes: 66 additions & 197 deletions rerun_cpp/src/rerun/components/.gitattributes

Large diffs are not rendered by default.

260 changes: 62 additions & 198 deletions rerun_cpp/src/rerun/datatypes/.gitattributes

Large diffs are not rendered by default.

11 changes: 6 additions & 5 deletions rerun_cpp/tests/generated/.gitattributes

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 10 additions & 10 deletions rerun_cpp/tests/generated/archetypes/.gitattributes

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

152 changes: 44 additions & 108 deletions rerun_cpp/tests/generated/components/.gitattributes

Large diffs are not rendered by default.

55 changes: 22 additions & 33 deletions rerun_cpp/tests/generated/datatypes/.gitattributes

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit cc4bb19

Please sign in to comment.