File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -114,11 +114,12 @@ files in subdirectories."
114
114
(setq our-elixir-format-arguments (append our-elixir-format-arguments elixir-format-arguments)))
115
115
(setq our-elixir-format-arguments (append our-elixir-format-arguments (list tmpfile)))
116
116
117
- (if (zerop (elixir-format--from-mix-root (elixir-format--mix-executable) (elixir-format--errbuff) our-elixir-format-arguments))
118
- (elixir-format--call-format-command tmpfile)
119
- (elixir-format--failed-to-format called-interactively-p))
120
- (delete-file tmpfile)
121
- (kill-buffer (elixir-format--outbuff))))
117
+ (unwind-protect
118
+ (if (zerop (elixir-format--from-mix-root (elixir-format--mix-executable) (elixir-format--errbuff) our-elixir-format-arguments))
119
+ (elixir-format--call-format-command tmpfile)
120
+ (elixir-format--failed-to-format called-interactively-p))
121
+ (delete-file tmpfile)
122
+ (kill-buffer (elixir-format--outbuff)))))
122
123
123
124
(defun elixir-format--call-format-command (tmpfile )
124
125
(if (zerop (call-process-region (point-min ) (point-max ) " diff" nil (elixir-format--outbuff) nil " -n" " -" tmpfile))
You can’t perform that action at this time.
0 commit comments