Skip to content

Commit

Permalink
Merge pull request #4 from emacs-rustic/format-start-process-broken-o…
Browse files Browse the repository at this point in the history
…n-remote

Make `rustic-format-start-process' work over tramp.
  • Loading branch information
CeleritasCelery authored May 17, 2024
2 parents 63ce443 + 446043c commit 7e51d36
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions rustic-rustfmt.el
Original file line number Diff line number Diff line change
Expand Up @@ -116,14 +116,15 @@ and it's `cdr' is a list of arguments."
(command (or (plist-get args :command)
(rustic-compute-rustfmt-args)))
(command (if (listp command) command (list command)))
(cur-buf (current-buffer)))
(cur-buf (current-buffer))
(rustfmt (rustic-rustfmt-bin)))
(setq rustic-save-pos (set-marker (make-marker) (point) (current-buffer)))
(rustic-compilation-setup-buffer err-buf dir 'rustic-format-mode t)
(--each files
(unless (file-exists-p it)
(error (format "File %s does not exist." it))))
(with-current-buffer err-buf
(let* ((c `(,(rustic-rustfmt-bin)
(let* ((c `(,rustfmt
,@(split-string rustic-rustfmt-args)
,@command "--" ,@files))
(proc (rustic-make-process :name rustic-format-process-name
Expand Down

0 comments on commit 7e51d36

Please sign in to comment.