Skip to content

Conversation

coopergillan
Copy link
Collaborator

What

Add a one-line rust_mappings.vim file allowing rustfmt to be automatically run when a buffer is saved, then include that runtime in vimrc.

Note that this only leveraging existing functionality in the already-implemented rust-lang/rust.vim plugin. See "Formatting with rustfmt" docs here.

Why

This will allow for a more consistent style used throughout Rust projects by running the formatter on each save.

@aklitzke - any issues with having rustfmt run automatically on save?

Add a one-line rust_mappings.vim file allowing `rustfmt` to be
automatically run when a buffer is saved, then include that
runtime in `vimrc`.

This will allow for a more consistent style used throughout Rust
projects by running the formatter on each save.
@cosgroveb
Copy link
Collaborator

I think this would be better placed in ftplugin, per #208. Thoughts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants