google / styleguide

Style guides for Google-originated open-source projects
https://google.github.io/styleguide/
Apache License 2.0
37.37k stars 13.3k forks source link

Rust style guide? #276

Open crlf0710 opened 7 years ago

crlf0710 commented 7 years ago

Now that there're projects written in Rust like google/xi-editor. I wonder if there're any plans to add a rust style guide?

OfekShochat commented 3 years ago

When will this be brought up again? I use c++'s google style guide and I really like it. I tried to partially replicate that style in rustfmt, would you be interested in seeing it?

gribozavr commented 3 years ago

Sorry, but I'm not aware of any such plans.

vapier commented 3 months ago

we don't have much atm. we're just running rustfmt on code and enforcing that. here's our rustfmt.toml.

edition = "2021"
version = "Two"

# The "Default" setting has a heuristic which splits lines too aggresively.
# We are willing to revisit this setting in future versions of rustfmt.
# Bugs:
#   * https://github.com/rust-lang/rustfmt/issues/3119
#   * https://github.com/rust-lang/rustfmt/issues/3120
use_small_heuristics = "Max"

newline_style = "Unix"

wrap_comments = true

format_generated_files = false