-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrustfmt.toml
More file actions
75 lines (66 loc) · 1.77 KB
/
rustfmt.toml
File metadata and controls
75 lines (66 loc) · 1.77 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
# file: .github/linters/rustfmt.toml
# version: 1.0.0
# guid: 5e6f7a8b-9c0d-1234-ef56-789abcdef012
# Rust formatting configuration following Rust Style Guide
# https://doc.rust-lang.org/nightly/style-guide/
# Edition and version
edition = "2021"
version = "Two"
# Basic formatting
max_width = 100
hard_tabs = false
tab_spaces = 4
newline_style = "Unix"
# Imports
imports_layout = "Vertical"
imports_granularity = "Crate"
group_imports = "StdExternalCrate"
reorder_imports = true
reorder_modules = true
# Functions
fn_params_layout = "Tall"
brace_style = "SameLineWhere"
control_brace_style = "AlwaysSameLine"
# Strings and comments
format_strings = true
format_macro_matchers = true
normalize_comments = true
normalize_doc_attributes = true
wrap_comments = true
comment_width = 80
# Expressions and statements
chain_width = 60
single_line_if_else_max_width = 50
where_single_line = true
force_explicit_abi = true
# Whitespace and indentation
blank_lines_upper_bound = 1
blank_lines_lower_bound = 0
empty_item_single_line = true
struct_lit_single_line = true
fn_single_line = false
# Advanced options
use_small_heuristics = "Default"
binop_separator = "Front"
combine_control_expr = true
condense_wildcard_suffixes = false
force_multiline_blocks = false
format_code_in_doc_comments = false
hex_literal_case = "Preserve"
ignore = []
license_template_path = ""
merge_derives = true
overflow_delimited_expr = false
remove_nested_parens = true
short_array_element = 10
spaces_around_ranges = false
struct_field_align_threshold = 0
trailing_comma = "Vertical"
trailing_semicolon = true
type_punctuation_density = "Wide"
unstable_features = false
use_field_init_shorthand = false
use_try_shorthand = false
match_arm_blocks = true
match_block_trailing_comma = false
spaces_within_parens_and_brackets = false