Skip to content

Commit 0d79e4c

Browse files
Switch buffers after spawning rustfmt (#58)
This fixes a problem wherein buffer-local values for rustic-rustfmt-args were effectively ignored
1 parent 1291904 commit 0d79e4c

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

rustic-rustfmt.el

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -123,16 +123,16 @@ and it's `cdr' is a list of arguments."
123123
(--each files
124124
(unless (file-exists-p it)
125125
(error (format "File %s does not exist." it))))
126-
(with-current-buffer err-buf
127-
(let* ((c `(,rustfmt
128-
,@(split-string rustic-rustfmt-args)
129-
,@command "--" ,@files))
130-
(proc (rustic-make-process :name rustic-format-process-name
131-
:buffer err-buf
132-
:command (remove "" c)
133-
:filter #'rustic-compilation-filter
134-
:sentinel sentinel
135-
:file-handler t)))
126+
(let* ((c `(,rustfmt
127+
,@(split-string rustic-rustfmt-args)
128+
,@command "--" ,@files))
129+
(proc (rustic-make-process :name rustic-format-process-name
130+
:buffer err-buf
131+
:command (remove "" c)
132+
:filter #'rustic-compilation-filter
133+
:sentinel sentinel
134+
:file-handler t)))
135+
(with-current-buffer err-buf
136136
(setq next-error-last-buffer buffer)
137137
(when string
138138
(process-put proc 'command-buf cur-buf)

0 commit comments

Comments
 (0)