File tree Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -31,6 +31,11 @@ worksapce for commands like `cargo check`."
31
31
:type 'string
32
32
:group 'rust-mode )
33
33
34
+ (defcustom rust-cargo-clippy-default-arguments '()
35
+ " Default arguments for running `cargo clippy`."
36
+ :type '(repeat string)
37
+ :group 'rust-mode )
38
+
34
39
; ;; Buffer Project
35
40
36
41
(defvar-local rust-buffer-project nil )
@@ -134,11 +139,13 @@ output buffer will be in comint mode, i.e. interactive."
134
139
(interactive )
135
140
(when (null rust-buffer-project)
136
141
(rust-update-buffer-project))
137
- (let* ((args (list rust-cargo-bin " clippy"
138
- (concat " --manifest-path=" rust-buffer-project)))
142
+ (let* ((args (append (list rust-cargo-bin " clippy"
143
+ (concat " --manifest-path=" rust-buffer-project))
144
+ rust-cargo-clippy-default-arguments))
139
145
; ; set `compile-command' temporarily so `compile' doesn't
140
146
; ; clobber the existing value
141
- (compile-command (mapconcat #'shell-quote-argument args " " )))
147
+ (compile-command (concat (mapconcat #'shell-quote-argument args " " )
148
+ " " rust-cargo-default-arguments)))
142
149
(rust--compile nil compile-command)))
143
150
144
151
; ;; _
You can’t perform that action at this time.
0 commit comments