rust: adapt Cargo key binding to conventions
This commit is contained in:
parent
a386b5a7b7
commit
539ff8da7c
|
@ -14,12 +14,32 @@
|
|||
|
||||
## Description
|
||||
|
||||
This layer aims to support Rust development in Spacemacs.
|
||||
This layer aims to support [Rust][] development in Spacemacs.
|
||||
|
||||
For now only basic support for [Cargo][] is provided.
|
||||
|
||||
## Install
|
||||
|
||||
### Layer
|
||||
|
||||
To use this layer, add it to your `~/.spacemacs`
|
||||
|
||||
```elisp
|
||||
(setq-default dotspacemacs-configuration-layers '(rust))
|
||||
```
|
||||
|
||||
### Cargo
|
||||
|
||||
[Cargo][] is a project management command line tool for Rust.
|
||||
Installation instructions can be found on the main page of [Cargo][].
|
||||
|
||||
## Key bindings
|
||||
|
||||
Key Binding | Description
|
||||
---------------------|------------------------------------------------------------
|
||||
<kbd>SPC m c c</kbd> | compile project with Cargo
|
||||
<kbd>SPC m c x</kbd> | compile and execute project with Cargo
|
||||
<kbd>SPC m t a</kbd> | execute all tests with Cargo
|
||||
|
||||
[Rust]: http://www.rust-lang.org/
|
||||
[Cargo]: http://doc.crates.io/index.html
|
||||
|
|
|
@ -41,9 +41,9 @@ which require an initialization must be listed explicitly in the list.")
|
|||
|
||||
;; (spacemacs/declare-prefix-for-mode 'rust-mode "mc" "cargo")
|
||||
(evil-leader/set-key-for-mode 'rust-mode
|
||||
"mcb" 'spacemacs/rust-cargo-build
|
||||
"mcr" 'spacemacs/rust-cargo-run
|
||||
"mct" 'spacemacs/rust-cargo-test)))
|
||||
"mcc" 'spacemacs/rust-cargo-build
|
||||
"mcC" 'spacemacs/rust-cargo-run
|
||||
"mta" 'spacemacs/rust-cargo-test)))
|
||||
"Initialize rust-mode"
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in a new issue