Files
MIT/rustfmt.toml
2023-12-22 09:03:51 +08:00

28 lines
725 B
TOML
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Run rustfmt with this config (it should be picked up automatically).
version = "Two"
use_small_heuristics = "Max"
max_width = 120
struct_lit_width = 60
chain_width = 80
single_line_if_else_max_width = 60
single_line_let_else_max_width = 60
merge_derives = true
reorder_imports = true
unstable_features = true # 使能 unstable 特性
## unstable features below ##
# 格式化注释代码块Unstable
format_code_in_doc_comments = true
# 重新排序mod
reorder_modules = true
# 按照 crate 重新排序
imports_granularity = "Crate"
# 过长换行使用大括号
match_arm_blocks = true
# 数组换行
indent_style = "Block"
# 彩色输出Unstable
color = "Auto"
# 忽略,也是 unstable 特性
ignore = ["tests"]