Skip to content

Instantly share code, notes, and snippets.

@faramozzayw
Created May 20, 2020 19:13
Show Gist options
  • Save faramozzayw/16aba2286d4395067c892bef6826e5a0 to your computer and use it in GitHub Desktop.
Save faramozzayw/16aba2286d4395067c892bef6826e5a0 to your computer and use it in GitHub Desktop.
indent_style = "Block"
tab_spaces = 4
reorder_imports = false
reorder_modules = false
# Put a trailing comma after a block based match arm (non-block arms are not affected)
# https://github.com/rust-lang/rustfmt/blob/master/Configurations.md#match_block_trailing_comma
match_block_trailing_comma = true
merge_derives = true
# Merge multiple imports into a single nested import.
# https://github.com/rust-lang/rustfmt/blob/master/Configurations.md#merge_imports
merge_imports = true
# Convert /* */ comments to // comments where possible
# https://github.com/rust-lang/rustfmt/blob/master/Configurations.md#normalize_comments
normalize_comments = true
# Convert #![doc] and #[doc] attributes to //! and /// doc comments.
# https://github.com/rust-lang/rustfmt/blob/master/Configurations.md#normalize_doc_attributes
normalize_doc_attributes = true
# Reorder impl items. type and const are put first, then macros and methods.
# https://github.com/rust-lang/rustfmt/blob/master/Configurations.md#reorder_impl_items
reorder_impl_items = true
# Put small struct literals on a single line
# https://github.com/rust-lang/rustfmt/blob/master/Configurations.md#struct_lit_single_line
struct_lit_single_line = false
# Replace strings of _ wildcards by a single .. in tuple patterns
# https://github.com/rust-lang/rustfmt/blob/master/Configurations.md#condense_wildcard_suffixes
condense_wildcard_suffixes = true
# Break comments to fit on the line
# https://github.com/rust-lang/rustfmt/blob/master/Configurations.md#wrap_comments
wrap_comments = true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment